Skip to content

Commit db192c3

Browse files
Revert "fixup!: try awaiting subtests"
This reverts commit d5e777d.
1 parent d5e777d commit db192c3

1 file changed

Lines changed: 12 additions & 14 deletions

File tree

test/parallel/test-runner-subtest-methods.js

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -20,20 +20,18 @@ test('subtest should return a promise', async (t) => {
2020
});
2121

2222
test('t.test[variant]() should return a promise', async (t) => {
23-
const xfail = t.test.expectFailure('expectFailure subtest', () => { throw new Error('This should pass'); });
24-
const only = t.test.only('only subtest');
25-
const skip = t.test.skip('skip subtest');
26-
const todo = t.test.todo('todo subtest');
27-
28-
assert.ok(isPromise(xfail));
29-
assert.ok(isPromise(only));
30-
assert.ok(isPromise(skip));
31-
assert.ok(isPromise(todo));
32-
33-
await xfail;
34-
await only;
35-
await skip;
36-
await todo;
23+
assert.ok(isPromise(
24+
t.test.expectFailure('expectFailure subtest', () => { throw new Error('This should pass'); })
25+
));
26+
assert.ok(isPromise(
27+
t.test.only('only subtest')
28+
));
29+
assert.ok(isPromise(
30+
t.test.skip('skip subtest')
31+
));
32+
assert.ok(isPromise(
33+
t.test.todo('todo subtest')
34+
));
3735
});
3836

3937
test('nested subtests should have test variants', async (t) => {

0 commit comments

Comments
 (0)