Reputation: 188
Is there a way to skip protractor test dynamically? I have scenarios where a user can select any specific test to perform. So, I want to execute only the tests user has specified and dependent tests, all other tests should be skipped.
I am using grunt-protractor-runner.
Upvotes: 3
Views: 2309
Reputation: 36
May be for you not actual. But it may be useful for other people. You can try to use the next construction:
it('your test', function(done)){
if('user action or result of user action'){
console.log("Test is skiped");
done();
}
//other test's code
...................
done();
}
Upvotes: 0
Reputation: 4296
As shown in this question, you can specify a URL of a specific spec. Otherwise you'd have to use the focused fdescribe/fit but you can't change it in runtime. This is not related to Protractor but rather specific to Jasmine.
Upvotes: 1