From de8df42c05a1b8fe57793432fe4733bca53d1e78 Mon Sep 17 00:00:00 2001 From: Stef Schenkelaars Date: Thu, 10 Sep 2020 10:29:58 +0200 Subject: [PATCH] Add e2e example spec --- .github/workflows/ci.yml | 26 +++++++++++++++++++++++++- spec/integration/failing_spec.rb | 13 +++++++++++++ 2 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 spec/integration/failing_spec.rb diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d1e03f7..2ee5119 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,4 +33,28 @@ jobs: bundle config path vendor/bundle bundle install --jobs 4 --retry 3 - name: Run RSpec - run: bundle exec rspec + run: bundle exec rspec spec/rspec + e2e: + continue-on-error: true + runs-on: ubuntu-latest + steps: + - name: Check out code + uses: actions/checkout@v1 + - name: Setup caching for ruby gems + uses: actions/cache@v1 + with: + path: vendor/bundle + key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }} + restore-keys: | + ${{ runner.os }}-gems- + - name: Setup Ruby + uses: actions/setup-ruby@v1 + with: + ruby-version: 2.7 + - name: Install gems + run: | + gem install bundler:2.1.4 --no-doc + bundle config path vendor/bundle + bundle install --jobs 4 --retry 3 + - name: Run RSpec + run: '! bundle exec rspec spec/integration' diff --git a/spec/integration/failing_spec.rb b/spec/integration/failing_spec.rb new file mode 100644 index 0000000..d293e81 --- /dev/null +++ b/spec/integration/failing_spec.rb @@ -0,0 +1,13 @@ +# frozen_string_literal: true + +RSpec.describe RSpec::Github do + it 'creates an error annotation for failing specs' do + expect(true).to eq false + end + + it 'creates a warning annotation for pending specs' + + it 'does not create an annotiation for passing specs' do + expect(true).to eq true + end +end