spreewald 3.0.2 → 4.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +42 -0
- data/.ruby-version +1 -1
- data/CHANGELOG.md +29 -0
- data/Gemfile +1 -1
- data/Gemfile.lock +2 -2
- data/Gemfile.ruby245 +3 -0
- data/Gemfile.ruby245.lock +11 -2
- data/Gemfile.ruby266 +3 -0
- data/Gemfile.ruby266.lock +12 -2
- data/{Gemfile.ruby218 → Gemfile.ruby300} +6 -1
- data/Gemfile.ruby300.lock +108 -0
- data/README.md +41 -3
- data/Rakefile +34 -19
- data/features/binary.feature +2 -2
- data/features/support/step_definitions/custom_steps.rb +10 -0
- data/lib/spreewald.rb +1 -0
- data/lib/spreewald/browser_tab_steps.rb +1 -1
- data/lib/spreewald/development_steps.rb +5 -5
- data/lib/spreewald/email_steps.rb +3 -1
- data/lib/spreewald/frame_steps.rb +77 -0
- data/lib/spreewald_support/mail_finder.rb +11 -10
- data/lib/spreewald_support/mail_to_plaintext_converter.rb +42 -0
- data/lib/spreewald_support/unsupported_email_header.rb +22 -0
- data/lib/spreewald_support/version.rb +1 -1
- data/spec/spreewald_support/mail_to_plaintext_converter_spec.rb +60 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/Gemfile +1 -1
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/Gemfile.lock +15 -17
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/README.rdoc +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/Rakefile +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/app +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/bin/bundle +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/bin/rails +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/bin/rake +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/bin/setup +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config.ru +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/application.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/boot.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/cucumber.yml +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/database.yml +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/environment.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/environments/development.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/environments/test.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/backtrace_silencers.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/cookies_serializer.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/filter_parameter_logging.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/inflections.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/mime_types.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/session_store.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/silence_deprecation_warnings.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/to_time_preserves_timezone.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/initializers/wrap_parameters.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/locales/en.yml +0 -0
- data/tests/{rails-3_capybara-1 → rails-4_capybara-2}/config/routes.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/config/secrets.yml +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/db +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/browser_tab_steps.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/development_steps.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/email_steps.feature +0 -0
- data/tests/rails-4_capybara-2/features/iframe_steps.feature +1 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/overriding.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/session_steps.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/step_definitions/overriding_steps.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/step_definitions/test_steps.rb +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/support/env.rb +0 -0
- data/tests/{rails-3_capybara-1 → rails-4_capybara-2}/features/support/paths.rb +0 -0
- data/tests/{rails-3_capybara-1 → rails-4_capybara-2}/features/support/selectors.rb +0 -0
- data/tests/rails-4_capybara-2/features/support/selenium.rb +1 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/table_steps.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/time_steps.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/features/web_steps.feature +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/lib/tasks/cucumber.rake +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/log/.keep +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/public/404.html +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/public/422.html +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/public/500.html +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/public/favicon.ico +0 -0
- data/tests/{rails-4_capybara-3 → rails-4_capybara-2}/public/fixture_files +0 -0
- data/tests/{rails-3_capybara-1 → rails-4_capybara-2}/script/cucumber +0 -0
- data/tests/rails-6_capybara-3/.ruby-version +1 -1
- data/tests/rails-6_capybara-3/Gemfile +4 -2
- data/tests/rails-6_capybara-3/Gemfile.lock +177 -143
- data/tests/rails-6_capybara-3/app/mailers/spreewald_mailer.rb +16 -0
- data/tests/rails-6_capybara-3/config.ru +1 -0
- data/tests/rails-6_capybara-3/config/cucumber.yml +1 -1
- data/tests/rails-6_capybara-3/config/environments/development.rb +21 -3
- data/tests/rails-6_capybara-3/config/environments/test.rb +12 -1
- data/tests/rails-6_capybara-3/config/initializers/backtrace_silencers.rb +4 -3
- data/tests/rails-6_capybara-3/config/initializers/filter_parameter_logging.rb +3 -1
- data/tests/rails-6_capybara-3/config/initializers/new_framework_defaults_6_1.rb +67 -0
- data/tests/rails-6_capybara-3/config/initializers/permissions_policy.rb +11 -0
- data/tests/rails-6_capybara-3/features/iframe_steps.feature +1 -0
- data/tests/rails-6_capybara-3/features/support/selenium.rb +1 -0
- data/tests/shared/app/controllers/emails_controller.rb +20 -0
- data/tests/shared/app/controllers/iframes_controller.rb +11 -0
- data/tests/shared/app/controllers/static_pages_controller.rb +12 -8
- data/tests/shared/app/models/mailer.rb +32 -0
- data/tests/shared/app/views/iframes/iframe_1_content.haml +12 -0
- data/tests/shared/app/views/iframes/iframe_2_content.haml +12 -0
- data/tests/shared/app/views/mailer/html_email_for_failed_test_without_header.haml +5 -0
- data/tests/shared/app/views/mailer/html_email_for_successful_test_without_header.haml +7 -0
- data/tests/shared/app/views/mailer/text_email_for_failed_test_without_header.text.erb +1 -0
- data/tests/shared/app/views/mailer/text_email_for_successful_test_without_header.text.erb +3 -0
- data/tests/shared/app/views/static_pages/iframe.haml +3 -0
- data/tests/shared/config/routes.rb +8 -0
- data/tests/shared/features/shared/email_steps.feature +185 -0
- data/tests/shared/features/shared/iframe_steps.feature +38 -0
- data/tests/shared/features/shared/step_definitions/test_steps.rb +5 -6
- data/tests/shared/features/support/selenium.rb +10 -0
- metadata +143 -184
- data/.travis.yml +0 -29
- data/Gemfile.ruby218.lock +0 -58
- data/tests/rails-3_capybara-1/.ruby-version +0 -1
- data/tests/rails-3_capybara-1/Gemfile +0 -20
- data/tests/rails-3_capybara-1/Gemfile.lock +0 -182
- data/tests/rails-3_capybara-1/Rakefile +0 -18
- data/tests/rails-3_capybara-1/app +0 -1
- data/tests/rails-3_capybara-1/config.ru +0 -4
- data/tests/rails-3_capybara-1/config/application.rb +0 -29
- data/tests/rails-3_capybara-1/config/boot.rb +0 -15
- data/tests/rails-3_capybara-1/config/cucumber.yml +0 -1
- data/tests/rails-3_capybara-1/config/database.yml +0 -1
- data/tests/rails-3_capybara-1/config/environment.rb +0 -7
- data/tests/rails-3_capybara-1/config/initializers/backtrace_silencers.rb +0 -9
- data/tests/rails-3_capybara-1/config/initializers/inflections.rb +0 -12
- data/tests/rails-3_capybara-1/config/initializers/mime_types.rb +0 -7
- data/tests/rails-3_capybara-1/config/initializers/secret_token.rb +0 -9
- data/tests/rails-3_capybara-1/config/initializers/session_store.rb +0 -5
- data/tests/rails-3_capybara-1/db +0 -1
- data/tests/rails-3_capybara-1/features/shared +0 -1
- data/tests/rails-3_capybara-1/features/support/env.rb +0 -65
- data/tests/rails-3_capybara-1/features/support/selenium.rb +0 -3
- data/tests/rails-3_capybara-1/public +0 -1
- data/tests/rails-3_capybara-1/script/rails +0 -6
- data/tests/rails-3_capybara-2/.ruby-version +0 -1
- data/tests/rails-3_capybara-2/Gemfile +0 -21
- data/tests/rails-3_capybara-2/Gemfile.lock +0 -191
- data/tests/rails-3_capybara-2/Rakefile +0 -1
- data/tests/rails-3_capybara-2/app +0 -1
- data/tests/rails-3_capybara-2/config +0 -1
- data/tests/rails-3_capybara-2/config.ru +0 -1
- data/tests/rails-3_capybara-2/db +0 -1
- data/tests/rails-3_capybara-2/features +0 -1
- data/tests/rails-3_capybara-2/public +0 -1
- data/tests/rails-3_capybara-2/script +0 -1
- data/tests/rails-4_capybara-3/config/routes.rb +0 -1
- data/tests/rails-4_capybara-3/features/support/paths.rb +0 -1
- data/tests/rails-4_capybara-3/features/support/selectors.rb +0 -1
- data/tests/rails-4_capybara-3/features/support/selenium.rb +0 -3
- data/tests/rails-4_capybara-3/script/cucumber +0 -10
- data/tests/rails-6_capybara-3/features/support/selenium.rb +0 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a4c751f9710de7f192ae23a8184dd2f7a929c2a9381f6fd3ee11e7f84c2012e4
|
|
4
|
+
data.tar.gz: 5f94bfcf3744f8f2f44d688129c4e490e98b987eb2c97116431c8e56a5b9714c
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 63d52ea274f3d44d63c460fd29adf935c77790093010b4dcfe2ddadf5a6f57a64407eeef686ad35acca5ee0ad79d2d0e6977886cad4d06ac17ba011c0b5287e7
|
|
7
|
+
data.tar.gz: 52dea6eae2351828a62aafc3d31fba6c0e156981c530cd8f67b3f0623516cea06ffe239af78b90562304cb5158e0bc5fc4836a28d02baae26b1401bee9236cc9
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Tests
|
|
3
|
+
'on':
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- master
|
|
7
|
+
pull_request:
|
|
8
|
+
branches:
|
|
9
|
+
- master
|
|
10
|
+
jobs:
|
|
11
|
+
test:
|
|
12
|
+
runs-on: ubuntu-20.04
|
|
13
|
+
strategy:
|
|
14
|
+
fail-fast: false
|
|
15
|
+
matrix:
|
|
16
|
+
include:
|
|
17
|
+
# Test projects
|
|
18
|
+
- ruby: 2.4.5
|
|
19
|
+
gemfile: tests/rails-4_capybara-2/Gemfile
|
|
20
|
+
- ruby: 3.0.0
|
|
21
|
+
gemfile: tests/rails-6_capybara-3/Gemfile
|
|
22
|
+
# Used to run rspec and integration tests for spreewald binary:
|
|
23
|
+
- ruby: 2.4.5
|
|
24
|
+
gemfile: Gemfile.ruby245
|
|
25
|
+
- ruby: 2.6.6
|
|
26
|
+
gemfile: Gemfile.ruby266
|
|
27
|
+
- ruby: 3.0.0
|
|
28
|
+
gemfile: Gemfile.ruby300
|
|
29
|
+
env:
|
|
30
|
+
BUNDLE_GEMFILE: "${{ matrix.gemfile }}"
|
|
31
|
+
steps:
|
|
32
|
+
- uses: actions/checkout@v2
|
|
33
|
+
- name: Install ruby
|
|
34
|
+
uses: ruby/setup-ruby@v1
|
|
35
|
+
with:
|
|
36
|
+
ruby-version: "${{ matrix.ruby }}"
|
|
37
|
+
- name: Bundle
|
|
38
|
+
run: |
|
|
39
|
+
gem install bundler:1.17.3
|
|
40
|
+
bundle install --no-deployment
|
|
41
|
+
- name: Run tests
|
|
42
|
+
run: bundle exec rake matrix:single_test[${{ matrix.gemfile }},${{ matrix.ruby }}]
|
data/.ruby-version
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
3.0.0
|
data/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,35 @@ All notable changes to this project will be documented in this file.
|
|
|
3
3
|
|
|
4
4
|
This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
5
5
|
|
|
6
|
+
## 4.1.2
|
|
7
|
+
- Multiple invocations of console don't raise anymore
|
|
8
|
+
|
|
9
|
+
## 4.1.1
|
|
10
|
+
- The step `I open .. in a new browser tab` is now using the `noopener` option (see issue [#174])
|
|
11
|
+
|
|
12
|
+
## 4.1.0
|
|
13
|
+
|
|
14
|
+
- New steps:
|
|
15
|
+
- When ... inside the ... iframe
|
|
16
|
+
|
|
17
|
+
- New steps only available for Capybara 3+:
|
|
18
|
+
- When I switch to the ... iframe
|
|
19
|
+
- When I switch back to the whole page
|
|
20
|
+
- The I switch back to the whole page step does not work reliably with Capybara 2 and lead to StaleReferenceErrors, therefore we decided to not make these steps available for Capybara 2.
|
|
21
|
+
|
|
22
|
+
- Small improvements:
|
|
23
|
+
- Trying to match against unsupported email headers will raise an error. Supported headers are "To", "CC", "BCC", "From", "Reply-To", "Subject", "Attachments"
|
|
24
|
+
- It's now possible to have indented header lines in email steps.
|
|
25
|
+
- If there's not an explicit text part in a mail, Spreewald determines if the email body is HTML or plaintext and converts it to plaintext accordingly.
|
|
26
|
+
|
|
27
|
+
## 4.0.0
|
|
28
|
+
|
|
29
|
+
- Dropped support for capybara 1, Ruby 2.1 and Rails 3.2.
|
|
30
|
+
|
|
31
|
+
## 3.0.3
|
|
32
|
+
|
|
33
|
+
- The `an email should have been sent with` step now interprets all lines as body when not specifying headers (see issue [#157](https://github.com/makandra/spreewald/issues/157))
|
|
34
|
+
|
|
6
35
|
## 3.0.2
|
|
7
36
|
|
|
8
37
|
- Introduce wildcard for the beginning of a line. (see issue [#155](https://github.com/makandra/spreewald/issues/155))
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
data/Gemfile.ruby245
CHANGED
data/Gemfile.ruby245.lock
CHANGED
|
@@ -31,10 +31,16 @@ GEM
|
|
|
31
31
|
cucumber-wire (0.0.1)
|
|
32
32
|
diff-lcs (1.3)
|
|
33
33
|
ffi (1.10.0)
|
|
34
|
-
gemika (0.
|
|
34
|
+
gemika (0.5.0)
|
|
35
35
|
gherkin (5.1.0)
|
|
36
|
+
mail (2.7.1)
|
|
37
|
+
mini_mime (>= 0.1.1)
|
|
38
|
+
mini_mime (1.0.1)
|
|
39
|
+
mini_portile2 (2.4.0)
|
|
36
40
|
multi_json (1.13.1)
|
|
37
41
|
multi_test (0.1.2)
|
|
42
|
+
nokogiri (1.10.10)
|
|
43
|
+
mini_portile2 (~> 2.4.0)
|
|
38
44
|
rake (12.3.2)
|
|
39
45
|
rspec (3.8.0)
|
|
40
46
|
rspec-core (~> 3.8.0)
|
|
@@ -58,7 +64,10 @@ DEPENDENCIES
|
|
|
58
64
|
aruba
|
|
59
65
|
cucumber
|
|
60
66
|
gemika
|
|
67
|
+
mail
|
|
68
|
+
nokogiri
|
|
69
|
+
rake
|
|
61
70
|
rspec
|
|
62
71
|
|
|
63
72
|
BUNDLED WITH
|
|
64
|
-
|
|
73
|
+
2.2.4
|
data/Gemfile.ruby266
CHANGED
data/Gemfile.ruby266.lock
CHANGED
|
@@ -30,10 +30,17 @@ GEM
|
|
|
30
30
|
cucumber-wire (0.0.1)
|
|
31
31
|
diff-lcs (1.3)
|
|
32
32
|
ffi (1.12.2)
|
|
33
|
-
gemika (0.
|
|
33
|
+
gemika (0.5.0)
|
|
34
34
|
gherkin (5.1.0)
|
|
35
|
+
mail (2.7.1)
|
|
36
|
+
mini_mime (>= 0.1.1)
|
|
37
|
+
mini_mime (1.0.2)
|
|
35
38
|
multi_json (1.14.1)
|
|
36
39
|
multi_test (0.1.2)
|
|
40
|
+
nokogiri (1.11.1-x86_64-linux)
|
|
41
|
+
racc (~> 1.4)
|
|
42
|
+
racc (1.5.2)
|
|
43
|
+
rake (13.0.3)
|
|
37
44
|
rspec (3.9.0)
|
|
38
45
|
rspec-core (~> 3.9.0)
|
|
39
46
|
rspec-expectations (~> 3.9.0)
|
|
@@ -56,10 +63,13 @@ DEPENDENCIES
|
|
|
56
63
|
aruba
|
|
57
64
|
cucumber
|
|
58
65
|
gemika
|
|
66
|
+
mail
|
|
67
|
+
nokogiri
|
|
68
|
+
rake
|
|
59
69
|
rspec
|
|
60
70
|
|
|
61
71
|
RUBY VERSION
|
|
62
72
|
ruby 2.6.6p146
|
|
63
73
|
|
|
64
74
|
BUNDLED WITH
|
|
65
|
-
2.
|
|
75
|
+
2.2.14
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
GEM
|
|
2
|
+
remote: https://rubygems.org/
|
|
3
|
+
specs:
|
|
4
|
+
activesupport (6.1.3.1)
|
|
5
|
+
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
6
|
+
i18n (>= 1.6, < 2)
|
|
7
|
+
minitest (>= 5.1)
|
|
8
|
+
tzinfo (~> 2.0)
|
|
9
|
+
zeitwerk (~> 2.3)
|
|
10
|
+
aruba (1.0.4)
|
|
11
|
+
childprocess (>= 2.0, < 5.0)
|
|
12
|
+
contracts (~> 0.16.0)
|
|
13
|
+
cucumber (>= 2.4, < 6.0)
|
|
14
|
+
rspec-expectations (~> 3.4)
|
|
15
|
+
thor (~> 1.0)
|
|
16
|
+
builder (3.2.4)
|
|
17
|
+
childprocess (4.0.0)
|
|
18
|
+
concurrent-ruby (1.1.8)
|
|
19
|
+
contracts (0.16.0)
|
|
20
|
+
cucumber (5.3.0)
|
|
21
|
+
builder (~> 3.2, >= 3.2.4)
|
|
22
|
+
cucumber-core (~> 8.0, >= 8.0.1)
|
|
23
|
+
cucumber-create-meta (~> 2.0, >= 2.0.2)
|
|
24
|
+
cucumber-cucumber-expressions (~> 10.3, >= 10.3.0)
|
|
25
|
+
cucumber-gherkin (~> 15.0, >= 15.0.2)
|
|
26
|
+
cucumber-html-formatter (~> 9.0, >= 9.0.0)
|
|
27
|
+
cucumber-messages (~> 13.1, >= 13.1.0)
|
|
28
|
+
cucumber-wire (~> 4.0, >= 4.0.1)
|
|
29
|
+
diff-lcs (~> 1.4, >= 1.4.4)
|
|
30
|
+
multi_test (~> 0.1, >= 0.1.2)
|
|
31
|
+
sys-uname (~> 1.2, >= 1.2.1)
|
|
32
|
+
cucumber-core (8.0.1)
|
|
33
|
+
cucumber-gherkin (~> 15.0, >= 15.0.2)
|
|
34
|
+
cucumber-messages (~> 13.0, >= 13.0.1)
|
|
35
|
+
cucumber-tag-expressions (~> 2.0, >= 2.0.4)
|
|
36
|
+
cucumber-create-meta (2.0.4)
|
|
37
|
+
cucumber-messages (~> 13.1, >= 13.1.0)
|
|
38
|
+
sys-uname (~> 1.2, >= 1.2.1)
|
|
39
|
+
cucumber-cucumber-expressions (10.3.0)
|
|
40
|
+
cucumber-gherkin (15.0.2)
|
|
41
|
+
cucumber-messages (~> 13.0, >= 13.0.1)
|
|
42
|
+
cucumber-html-formatter (9.0.0)
|
|
43
|
+
cucumber-messages (~> 13.0, >= 13.0.1)
|
|
44
|
+
cucumber-messages (13.2.1)
|
|
45
|
+
protobuf-cucumber (~> 3.10, >= 3.10.8)
|
|
46
|
+
cucumber-tag-expressions (2.0.4)
|
|
47
|
+
cucumber-wire (4.0.1)
|
|
48
|
+
cucumber-core (~> 8.0, >= 8.0.1)
|
|
49
|
+
cucumber-cucumber-expressions (~> 10.3, >= 10.3.0)
|
|
50
|
+
cucumber-messages (~> 13.0, >= 13.0.1)
|
|
51
|
+
diff-lcs (1.4.4)
|
|
52
|
+
ffi (1.15.0)
|
|
53
|
+
gemika (0.5.0)
|
|
54
|
+
i18n (1.8.10)
|
|
55
|
+
concurrent-ruby (~> 1.0)
|
|
56
|
+
mail (2.7.1)
|
|
57
|
+
mini_mime (>= 0.1.1)
|
|
58
|
+
middleware (0.1.0)
|
|
59
|
+
mini_mime (1.0.3)
|
|
60
|
+
minitest (5.14.4)
|
|
61
|
+
multi_test (0.1.2)
|
|
62
|
+
nokogiri (1.11.2-x86_64-linux)
|
|
63
|
+
racc (~> 1.4)
|
|
64
|
+
protobuf-cucumber (3.10.8)
|
|
65
|
+
activesupport (>= 3.2)
|
|
66
|
+
middleware
|
|
67
|
+
thor
|
|
68
|
+
thread_safe
|
|
69
|
+
racc (1.5.2)
|
|
70
|
+
rake (13.0.3)
|
|
71
|
+
rspec (3.10.0)
|
|
72
|
+
rspec-core (~> 3.10.0)
|
|
73
|
+
rspec-expectations (~> 3.10.0)
|
|
74
|
+
rspec-mocks (~> 3.10.0)
|
|
75
|
+
rspec-core (3.10.1)
|
|
76
|
+
rspec-support (~> 3.10.0)
|
|
77
|
+
rspec-expectations (3.10.1)
|
|
78
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
|
79
|
+
rspec-support (~> 3.10.0)
|
|
80
|
+
rspec-mocks (3.10.2)
|
|
81
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
|
82
|
+
rspec-support (~> 3.10.0)
|
|
83
|
+
rspec-support (3.10.2)
|
|
84
|
+
sys-uname (1.2.2)
|
|
85
|
+
ffi (~> 1.1)
|
|
86
|
+
thor (1.1.0)
|
|
87
|
+
thread_safe (0.3.6)
|
|
88
|
+
tzinfo (2.0.4)
|
|
89
|
+
concurrent-ruby (~> 1.0)
|
|
90
|
+
zeitwerk (2.4.2)
|
|
91
|
+
|
|
92
|
+
PLATFORMS
|
|
93
|
+
x86_64-linux
|
|
94
|
+
|
|
95
|
+
DEPENDENCIES
|
|
96
|
+
aruba
|
|
97
|
+
cucumber
|
|
98
|
+
gemika
|
|
99
|
+
mail
|
|
100
|
+
nokogiri
|
|
101
|
+
rake
|
|
102
|
+
rspec
|
|
103
|
+
|
|
104
|
+
RUBY VERSION
|
|
105
|
+
ruby 3.0.0p0
|
|
106
|
+
|
|
107
|
+
BUNDLED WITH
|
|
108
|
+
2.2.3
|
data/README.md
CHANGED
|
@@ -19,9 +19,9 @@ Or install it yourself as:
|
|
|
19
19
|
$ gem install spreewald
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
## Supported
|
|
22
|
+
## Supported versions
|
|
23
23
|
|
|
24
|
-
Spreewald
|
|
24
|
+
Spreewald is currently tested against Ruby 2.4.5 with Rails 4 and Capybara 2 and Ruby 2.6.6 with Rails 6 and Capybara 3.
|
|
25
25
|
|
|
26
26
|
## Usage
|
|
27
27
|
|
|
@@ -237,7 +237,9 @@ the step definitions.
|
|
|
237
237
|
|
|
238
238
|
"""
|
|
239
239
|
|
|
240
|
-
You may skip lines in the header
|
|
240
|
+
You may skip lines in the header.
|
|
241
|
+
Please note: In older versions of Spreewald, unmentioned body lines were skipped.
|
|
242
|
+
Now you have to use the asterisk explicitly to omit lines in the body.
|
|
241
243
|
|
|
242
244
|
|
|
243
245
|
* **When I follow the (first|second|third)? link in the e?mail**
|
|
@@ -265,6 +267,42 @@ the step definitions.
|
|
|
265
267
|
This uses the same syntax as `Then an email should have been sent with:`
|
|
266
268
|
|
|
267
269
|
|
|
270
|
+
### frame_steps.rb
|
|
271
|
+
|
|
272
|
+
* **When ... inside the ... iframe**
|
|
273
|
+
|
|
274
|
+
You can append `inside the [name or number] iframe` to any other step.
|
|
275
|
+
Then the step will operate inside the given iframe.
|
|
276
|
+
Examples:
|
|
277
|
+
|
|
278
|
+
Then I should see "Kiwi" inside the 1st iframe
|
|
279
|
+
Then I should see "Cherry" inside the fruits iframe
|
|
280
|
+
When I press "Save" inside the 2nd iframe
|
|
281
|
+
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
* **When I switch to the ... iframe**
|
|
285
|
+
|
|
286
|
+
This step will switch to the iframe identified by its name or number.
|
|
287
|
+
All further steps will operate inside the iframe.
|
|
288
|
+
To switch to operating on the main page again, use the step
|
|
289
|
+
"I switch back to the whole page".
|
|
290
|
+
Examples:
|
|
291
|
+
|
|
292
|
+
When I switch to the 1st iframe
|
|
293
|
+
When I switch to the fruits iframe
|
|
294
|
+
|
|
295
|
+
Please note: This step is only available for Capybara >= 3.
|
|
296
|
+
|
|
297
|
+
|
|
298
|
+
* **When I switch back to the whole page**
|
|
299
|
+
|
|
300
|
+
This step can be used to switch back to the whole page if you switched
|
|
301
|
+
to operating inside an iframe before (step `I switch to the ... iframe`)
|
|
302
|
+
|
|
303
|
+
Please note: This step is only available for Capybara >= 3.
|
|
304
|
+
|
|
305
|
+
|
|
268
306
|
### session_steps.rb
|
|
269
307
|
|
|
270
308
|
* **When ... in the browser session "..."**
|
data/Rakefile
CHANGED
|
@@ -10,28 +10,25 @@ end
|
|
|
10
10
|
task :default => 'matrix:tests'
|
|
11
11
|
|
|
12
12
|
namespace :matrix do
|
|
13
|
+
desc 'Run tests for a single row of the matrix'
|
|
14
|
+
task :single_test, [:gemfile, :ruby] do |_t, args|
|
|
15
|
+
gemfile = args[:gemfile]
|
|
16
|
+
ruby = args[:ruby]
|
|
13
17
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
if directory.start_with?('tests')
|
|
19
|
-
# Run integration tests (uses embedded projects)
|
|
20
|
-
system(cucumber_command(directory, row.ruby))
|
|
21
|
-
else
|
|
22
|
-
# Run specs and tests for spreewald binary
|
|
23
|
-
[
|
|
24
|
-
system("BUNDLE_GEMFILE=#{row.gemfile} bundle exec rspec"),
|
|
25
|
-
system("BUNDLE_GEMFILE=#{row.gemfile} bundle exec cucumber"),
|
|
26
|
-
].all?
|
|
27
|
-
end
|
|
18
|
+
if gemfile.nil? || ruby.nil?
|
|
19
|
+
warn 'Please state the Gemfile and Ruby version to be used for the Testrun!'
|
|
20
|
+
else
|
|
21
|
+
run_tests(gemfile, ruby)
|
|
28
22
|
end
|
|
29
|
-
|
|
30
|
-
travis_yml = YAML.load_file('.travis.yml')
|
|
31
|
-
rubies = travis_yml.fetch('rvm') - [RUBY_VERSION]
|
|
32
|
-
puts "Please remember to run tests for the other ruby versions as well: #{rubies.join(", ")}"
|
|
33
23
|
end
|
|
34
24
|
|
|
25
|
+
|
|
26
|
+
desc "Run all tests which are available for current Ruby (#{RUBY_VERSION})"
|
|
27
|
+
task :tests, [:gemfile, :ruby] do |_t, args|
|
|
28
|
+
Gemika::Matrix.from_ci_config.each do |row|
|
|
29
|
+
run_tests(row.gemfile, row.ruby)
|
|
30
|
+
end
|
|
31
|
+
end
|
|
35
32
|
end
|
|
36
33
|
|
|
37
34
|
|
|
@@ -59,12 +56,30 @@ task :update_readme do
|
|
|
59
56
|
puts '', '> Done (diff applied).'
|
|
60
57
|
end
|
|
61
58
|
|
|
59
|
+
def run_tests(gemfile, ruby)
|
|
60
|
+
directory = File.dirname(gemfile)
|
|
61
|
+
if directory.start_with?('tests')
|
|
62
|
+
# Run integration tests (uses embedded projects)
|
|
63
|
+
system(cucumber_command(directory, ruby))
|
|
64
|
+
else
|
|
65
|
+
# Run specs and integration tests for Spreewald binary
|
|
66
|
+
[
|
|
67
|
+
system("BUNDLE_GEMFILE=#{gemfile} bundle exec rspec"),
|
|
68
|
+
system("BUNDLE_GEMFILE=#{gemfile} bundle exec cucumber --publish-quiet"),
|
|
69
|
+
].all?
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
|
|
62
73
|
def cucumber_command(directory, ruby_version)
|
|
63
|
-
command = "cd #{directory} && BUNDLE_GEMFILE=Gemfile
|
|
74
|
+
command = "cd #{directory} && BUNDLE_GEMFILE=Gemfile bundle exec cucumber --publish-quiet"
|
|
64
75
|
if Gem::Version.new(ruby_version) > Gem::Version.new('2.5')
|
|
65
76
|
# Modern cucumber sees pending tests as failures.
|
|
66
77
|
# We don't want this.
|
|
67
78
|
command << ' --no-strict-pending'
|
|
79
|
+
else
|
|
80
|
+
# Ruby < 2.5 means the capybara 2 Test project.
|
|
81
|
+
# Omit scenarios that only work with modern Capybara.
|
|
82
|
+
command << ' --tags "not @not-capybara-2"'
|
|
68
83
|
end
|
|
69
84
|
command
|
|
70
85
|
end
|