Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blowaway before hooks as well as after hooks to preserve order #2164

Merged
merged 2 commits into from Aug 27, 2019

Conversation

JonRowe
Copy link
Member

@JonRowe JonRowe commented Aug 23, 2019

I think this is the issue with #2153

@benoittgt
Copy link
Member

benoittgt commented Aug 24, 2019

Hello I tested with the repo provided by @alexsanderson.

With this branch

Using rspec-rails 4.0.0.beta2 from git://github.com/rspec/rspec-rails.git (at fix-teardown-hooks@395f34b)

I get a positive screenshot:

Capture d’écran 2019-08-24 à 14 42 29

This patch fix the issue. I don't know how much it is complicated to add test for this.

@benoittgt
Copy link
Member

benoittgt commented Aug 24, 2019

I am looking for the CI failures.

https://github.com/rspec/rspec-rails/blob/master/lib/rspec/rails/example/system_example_group.rb#L51

2.6.3 :002 > require 'action_dispatch/system_test_case'
Traceback (most recent call last):
       16: from /Users/bti/code/rspec-dev/repos/rspec-rails/spec/rspec/rails/example/system_example_group_spec.rb:11:in `block (4 levels) in <module:Rails>'
       15: from /Users/bti/code/rspec-dev/repos/rspec-rails/spec/rspec/rails/example/system_example_group_spec.rb:11:in `include'
       14: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/concern.rb:122:in `append_features'
       13: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/concern.rb:122:in `class_eval'
       12: from /Users/bti/code/rspec-dev/repos/rspec-rails/lib/rspec/rails/example/system_example_group.rb:50:in `block in <module:SystemExampleGroup>'
       11: from <internal:prelude>:145:in `irb'
       10: from (irb):2:in `block in <module:SystemExampleGroup>'
        9: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
        8: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:291:in `load_dependency'
        7: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `block in require'
        6: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
        5: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/actionpack-6.0.0/lib/action_dispatch/system_test_case.rb:7:in `<top (required)>'
        4: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
        3: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:291:in `load_dependency'
        2: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `block in require'
        1: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
LoadError (cannot load such file -- selenium/webdriver)

This is probably related to rails/rails@b21ef26#diff-ff5f366a442b8761d35f94807700fa77

Here is a commit: 00d33fa

@JonRowe
Copy link
Member Author

JonRowe commented Aug 25, 2019

I'm happy to merge this if you are @benoittgt I think the failures are the same as 4-0-dev normally right?

@benoittgt
Copy link
Member

Yep! Happy to merge

@JonRowe JonRowe merged commit b118fc6 into 4-0-dev Aug 27, 2019
@JonRowe JonRowe deleted the fix-teardown-hooks branch August 27, 2019 17:12
JonRowe added a commit that referenced this pull request Aug 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants