question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

If all scenarios pass on retry, protractor still exits with status code 1

See original GitHub issue

I 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:closed
  • Created 4 years ago
  • Reactions:3
  • Comments:24 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
Phonesiscommented, Jan 15, 2021

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

2reactions
achuinardcommented, Feb 3, 2020

It just was merged, @AlexandrosD do we need a version bump / release?

Read more comments on GitHub >

github_iconTop 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 >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found