DEV Community

n350071🇯🇵
n350071🇯🇵

Posted on

[Capybara] Debug for random error

🤔 What is random error

Unstable tests. When you run the feature spec, it sometimes goes to fail and sometimes go to success.

👍 1. Read the log and screenshot

omit.

👍 2. Run the unstable test for 100 times.

Of course, you can use binding.pry

100.times do
  scenario 'unstable test' do
    # test something
    binding.pry if something.is_not_expected
  end
end

👍 Other ways

  • under developmnet

🔥 Problems

🔗 Parent Note

Top comments (0)