diff --git a/doc/development/testing_guide/best_practices.md b/doc/development/testing_guide/best_practices.md index 613423dbd9a0d2d61dba56af8ee55227894557f2..b3ce2133161a399c360a3414ace86924a840e4a3 100644 --- a/doc/development/testing_guide/best_practices.md +++ b/doc/development/testing_guide/best_practices.md @@ -267,6 +267,20 @@ RSpec.configure do |config| end ``` +### Debugging + +If you need to debug Capybara tests, using the following lines, +you can get the current URL of Capybara server, logged in user email. Then you +can add some arbitrary sleep to halt the test and go check out the page. + +Default user password is `12345678`. + +``` +puts current_url +puts user.email +sleep(200) +``` + --- [Return to Testing documentation](index.md)