-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sync skip; aborting execution error thrown when this.skip() inside function #14867
Comments
I have the same issue, example project can be located here that reproduces the issue: https:/dthisner/cypressIssue |
As mentioned previously in the cucumber project, this can be reproduced solely in Cypress using the following code: it("should work", function () {
cy.then(() => this.skip()); // throws "sync skip; aborting execution"
}); This is /**
* Halt and mark as pending.
*
* @memberof Mocha.Runnable
* @public
*/
Runnable.prototype.skip = function() {
this.pending = true;
throw new Pending('sync skip; aborting execution');
}; I guess we're not handling this correctly in this case. This seems to have always errored in this case. |
I am facing same issue! |
Same issue for me, to avoid this issue I had to roll back to: |
The problem seems to be in the 6.4.0 version, the 6.3.0. works as expected |
problem seems to be solved in v. 6.5.0 |
Used 6.5.0 this morning and I got the same error when running tags in my repo. |
I see the same issue in 6.5.0 as well. |
I am having the same issue with version 7.0.1 |
Same thing in 7.2.0 :(. |
same issue on 7.4.0 |
This error will trigger Cypress to take screenshots and for the skip'd test. In the Cucumber scenario where many tests can be skipped based upon the specified tags, the number of screenshots could be significant; increasing test execution time and generating unnecessary screenshots. |
Try using this plugin https:/cypress-io/cypress-grep - I think it would make more sense to grep by title or tag rather than skip tests once the test has started. |
I'm same error yet! Do you some news? |
Same here with "cypress": "^7.7.0" and "cypress-cucumber-preprocessor": "^4.1.3" I don't even have any tags in my feature file. It's the same in Windows or in WSL. Ok for anyone wondering why it's not working with cypress-cucumber-preprocessor, if you have tags in your cypress open command you must use them. I had |
I'm not sure what's going on here, but I want to have multiple features and target a tag to run, like you're supposed to be able to do. Unfortunately, the second a file doesn't have the tag I specify, it stops ALL execution including any subsequent files that DO have the tag in them. This breaks my use-case and the intent of this feature. EDIT: So it has to do with headed mode with "--no-exit" enabled. With "cypress run," each spec (feature) runs in isolation (separate browser instance) so with the first test not exiting, we never get to the other files. |
Though it doesn't seem like a big deal on its own, this error is appearing as one of the top |
I was having this problem with Cypress 8.6.0, i did a downgrade to v8.3.1 and it worked. All version above of 8.3.1 to latest, the problem for me is happening. |
Using Cypress 8.7.0 and cypress-cucumber-preprocessor 4.3.0. |
The code for this is done in cypress-io/cypress#19279, but has yet to be released. |
The code for this is done in cypress-io/cypress#19331, but has yet to be released. |
Released in This comment thread has been locked. If you are still experiencing this issue after upgrading to |
Current behavior
Scenarios skipped with use of "@Focus" annotation generates a bug as seen on screenshot:
Focused scenario(s) run(s) correctly. It happened shortly after upgrading cypress to v.6.4.0 (I was using 6.3.0 before). Also I am using cypress-cucumber-preprocessor v.4.0.0. Problem disappears while running tests without annotation.
It's my first bug here so if you need any additional info please let me know, I will gladly provide :)
Desired behavior
It should simply run focused scenario(s) and skip the rest of them without failing .
Versions
Cypress v.6.4.0
cypress-cucumber-preprocessor v.4.0.0
The text was updated successfully, but these errors were encountered: