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

Screenshot is not captured in before hook #296

Open
mykulinn opened this issue Dec 16, 2024 · 0 comments
Open

Screenshot is not captured in before hook #296

mykulinn opened this issue Dec 16, 2024 · 0 comments

Comments

@mykulinn
Copy link

For some reason if I place same block of code in before hook, screenshot is not taken, even though exact same code in 'it' block triggers capybara to take screenshot. Looks like this:

screenshot is not taken:

describe 'title', type: :feature do
  include_context 'User logged in'
  
  describe 'When user logged in' do

    before(:all) { do_something_causing_fail }

    it 'Verify something' do
      expect(something).to eq something
    end
  end
end

screenshot is taken:

describe 'title', type: :feature do
  include_context 'User logged in'
  
  describe 'When user logged in' do

    before(:all) {  }

    it 'Verify something' do
      do_something_causing_fail
      expect(something).to eq something
    end
  end
end

Anybody had same issue before? Any help would be appreciated!

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

No branches or pull requests

1 participant