If all scenarios pass on retry, protractor still exits with status code 1
See original GitHub issueI am trying to debug an issue where I am using the new CucumberJS retry option yet the protractor process still returns an exit code of 1. My guess is that protractor-cucumber-framework reports the results to protractor which protractor then checks the failedCount
and exists appropriately.
I don’t know the best spot to fix this - in protractor? In protractor-cucumber-framework?
One idea I had was that protractor-cucumber-framework
would not report a failure to protractor if the retry worked, only if strict mode was false. Is this a valid option?
Right now, this is killing my ability to include this in my pipelines, as they evaluate the exit code. I would like my build to pass if everything works on retry.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:3
- Comments:24 (6 by maintainers)
Top Results From Across the Web
shell - Protractor - run test again if fails
Unfortunately if every failed scenario has been successfully retried, Protractor will still return with exit code 1: ...
Read more >protractor-retry
A solution to address the flakyness of your Protractor FE automation test suites. This module used protractor features to automatically re-run ...
Read more >Releases
Fixed dry-run to always return 0 code and exit; Added minimal version notice for NodeJS >= 12; fix(utils): remove . of test title...
Read more >Retry-ability
If the assertion still fails, Cypress continues retrying until the cy.find() timeout is reached. Retry-ability allows the test to complete each query as...
Read more >cucumber/cucumber-js - Gitter
I've been using jasmine and protractor- not sure when to choose one of the ... Every test works fine on its own, but...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I was never able to get it to work and ended up writing a script to handle the situation. It is annoying having to do it as adds a lot of overhead but works. It creates a txt file with a test/fail result logged for each test. At end of the run it will check if any txt file includes a fail status. If not, it will override exit code to ensure pipeline passes
It just was merged, @AlexandrosD do we need a version bump / release?