Debugging flaky browser specs in a Github Action (Flaky Specs part 5)
The most “fun” flaky spec to debug is a flaky browser spec that only fails intermittently in CI. What now?
To debug these effectively:
- Force your Github Action container to stay alive
- Provide a way to SSH in
- Provide a way to see the actual browser and interact with it
Capybara running over VNC in the Github Action container:
The above was setup using my “ci_vnc” scripts that are designed to setup SSH+VNC on a Github Action on EC2. I’m hoping to iterate on them and turn them into a reusable Github Actions Marketplace action.
That is the most secure method as it does not rely on any 3rd party service proxies like upterm
or ngrok
.
If you are OK with relying on such services, there is a more drop-in github action approach that relies on ngrok
.