-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[Feature] Add a skip request function #2116
Comments
Yes, it is useful indeed, we also use it in postman. So it could be the following syntax to be close to postman syntax: // set a local variable to true
// change to false to see all tests get executed
const skipTest = true;
// this test will always be executed
test("Status code is 200", function () {
expect(res.getStatus()).to.equal(200);
});
// this test will be skipped when skipTest is set to true
(skipTest ? test.skip : test)('Response time is less than 200ms', function () {
expect(res.getResponseTime()).to.be.below(200);
}); The skipped tests need to be counted in reports like the failed and passed tests. |
Looks like this has been built some months ago and awaiting to be merged into the main release. do we need the community to raise this visibility so that it can get prioritized? |
Hi @ben-sai, As you can see, @martinsefcik has suggested an improvement in the PR. Unfortunately, I haven’t been able to implement it in the past few weeks due to time constraints. However, I believe it would be best to incorporate this improvement before merging, so the feature can be at its best for all of us. |
Confirm, important function. |
I have checked the following:
Describe the feature you want to add
It will be useful to skip a request programmatically for example by testing a variable set by a previous request.
It could be useful to build more complex testing scenario.
Mockups or Images of the feature
This feature exists now in Postman
The text was updated successfully, but these errors were encountered: