Parallel: throw if Env#topSuite is called

This commit is contained in:
Steve Gravrock
2022-10-11 20:16:14 -07:00
parent e14d9c4be3
commit bb497beeff
3 changed files with 15 additions and 0 deletions

View File

@@ -81,6 +81,19 @@ describe('Env', function() {
);
expect(suite.children[1].children[1].children[0].children).toBeFalsy();
});
it('throws if called in parallel mode', function() {
env.setParallelLoadingState('helpers');
check();
env.setParallelLoadingState('specs');
check();
function check() {
expect(function() {
env.topSuite();
}).toThrowError("'topSuite' is not available in parallel mode");
}
});
});
it('accepts its own current configureation', function() {