Reputation: 5450
I have some unit test that should not be run, as of now, is there a way I can skip them? Other than using fdescribe on the ones I want to run.
Upvotes: 21
Views: 30529
Reputation: 3935
If you want to skip the entire test suite during run time based on some condition, you can do something like:
(yourCondition ? xdescribe : describe)('My Test Suite', function () {
...
})
Upvotes: 1
Reputation: 5967
If you're looking to skip tests, it's 'x' in front of describe() or it():
xdescribe('some test', () => { });
And maybe just skip a test in a block:
describe('some other test', () => {
xit('skip this test', () => { });
});
Upvotes: 42