mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-13 17:22:15 -05:00
test invert option (#20649)
This commit is contained in:
@@ -33,8 +33,6 @@ if (process.env.BUILD_ARTIFACTSTAGINGDIRECTORY) {
|
||||
};
|
||||
}
|
||||
|
||||
const mocha = new Mocha(options);
|
||||
|
||||
// {{SQL CARBON EDIT}} - If grep option is specified, only run the matching test cases (local test case development/debug scenario),
|
||||
// otherwise the value of 'RUN_UNSTABLE_TESTS' environment variable will be used to determine whether to run the stable test cases or the whole test suite.
|
||||
// Unstable test cases have "@UNSTABLE@" in their full name (test suite name + test name).
|
||||
@@ -43,12 +41,15 @@ if (!options.grep) {
|
||||
console.info('running all test cases.');
|
||||
} else {
|
||||
console.info('running stable test cases.');
|
||||
mocha.grep('@UNSTABLE@').invert();
|
||||
options.grep= '@UNSTABLE@';
|
||||
options.invert = true;
|
||||
}
|
||||
} else {
|
||||
console.info('running test cases match the grep option.');
|
||||
}
|
||||
// {{SQL CARBON EDIT}} - end of edit.
|
||||
|
||||
const mocha = new Mocha(options);
|
||||
|
||||
mocha.addFile('out/main.js');
|
||||
mocha.run(failures => process.exit(failures ? -1 : 0));
|
||||
|
||||
Reference in New Issue
Block a user