jquery / jquery/jquery-test-runner
Terminate a browser immediately when all tests are done on it
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 4
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Currently, JTR only terminates browsers when all tests are done in all requested browsers.
It's not a problem for our CI as we only run JTR on a single browser at a time, but it makes local test runs much more annoying.
For example, running the following in jQuery:
npm run test:unit -- -v -c jtr-isolate.yml --browserstack 'IE_11' --browserstack 'Chrome_latest' --browserstack 'Firefox_latest' --browserstack 'Safari_latest'
usually leads to modern browsers finishing quickly and waiting while IE is running tests. Since they wait for a long time, the browsers are idle for too long and... JTR (or something under the hood) thinks it's because the browser got stuck, restarts the browser and re-runs the last module tests on it (here: tween).
One possible solution to this would be to fix this detection, but needlessly keeping the browser running in idle mode is also not great; just terminating the browser when it's done would solve both issues at the same time.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the npm test command shown with multiple browsers and inspect the test-runner lifecycle around completion and browser termination. Trace how Selenium and BrowserStack sessions are managed; done means each browser is terminated as soon as its tests finish without being considered stuck or rerunning its last module.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- testing-qa
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100