rubyforgood / casa

Volunteer management system for nonprofit CASA, which serves foster youth in counties across America.
https://casavolunteertracking.org/
MIT License
314 stars 478 forks source link

Bug: Flaky Test #5120

Closed schoork closed 1 year ago

schoork commented 1 year ago

Flaky tests are defined as tests that return both passes and failures despite no changes to the code or the test itself Fix the test so it runs consistently.

CI Workflow

rspec

Sample Error Output:

1) view all volunteers supervisor user can persist 'show/hide' column preference settings
     Failure/Error: visit volunteers_path

     Selenium::WebDriver::Error::UnexpectedAlertOpenError:
       unexpected alert open: {Alert text : You need to sign in before continuing.}
         (Session info: headless chrome=115.0.5790.170)

rspec ./spec/system/volunteers/index_spec.rb:251 # view all volunteers supervisor user can persist 'show/hide' column preference settings

screenshot_2023-08-15-18-18-54 809

Questions? Join Slack!

We highly recommend that you join us in slack https://rubyforgood.herokuapp.com/ #casa channel to ask questions quickly and hear about office hours (currently Tuesday 5-7pm Pacific), stakeholder news, and upcoming new issues.

MarchandMD commented 1 year ago

Hey! I'm happy to tackle this!

I found this in the wild and have had some success getting past those flaky tests.

Please assign me and @Yuji3000 Thanks!

MarchandMD commented 1 year ago

Hey @schoork , can you provide a little more detail here; Were you experiencing issues in the CI workflow?

What are the steps I need to take to duplicate the errors you're seeing?

schoork commented 1 year ago

Hey @MarchandMD. It failed during a run of the Docker CI workflow, when it shouldn't have. Looking at the ticket now, I can't see the line in the test if failed on (Whoops!). If you can see anything in the test code that looks like it might be a little rickety, fix that. Otherwise, I'd say we close this with too little information.

Thanks for looking at it!

MarchandMD commented 1 year ago

@schoork I did research the Selenium webdriver issue, but I think that falls outside the scope of your intended ticket.

I'm fine with this being closed without more details. Thanks for the response.

Yuji3000 commented 1 year ago

@schoork Sounds good, Thanks for letting us know.

schoork commented 1 year ago

Not enough information to reproduce.