Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a script for testing actions locally
Using `act` [1]. However, act uses network mode `host` by default [2]. Multiple Cypress instances will check for X and start it, concurrently and not in an atomic way, causing issues. Container options specified in workflows and using --container-options *aren't* merged [3]. Furthermore, specifying a network option that works both on GHA and locally appears to be a bit tricky [4]. Thus, using `xvfb-run` to create a shared fb appears to be the easiest solution. However, `act` doesn't support env pass through, so we must parse `$DISPLAY` inside the xvfb environment in order to explicitly provide it to `act`. This would have all been unnecessary if `ELECTRON_RUN_AS_NODE` had even remotely worked [5]. [1] https://nektosact.com/ [2] nektos/act#1739 [3] nektos/act#1696 [4] nektos/act#1740 [5] cypress-io/cypress-documentation#5666
- Loading branch information