diff options
| author | David Sherret <dsherret@users.noreply.github.com> | 2021-10-11 09:45:02 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-11 09:45:02 -0400 |
| commit | 426ebf854a82c63cdaa2413fbd1b005025dba95b (patch) | |
| tree | 316a426e280db29745444e7606952c8c235c846a /cli/tests/testdata/test/steps/ignored_steps.ts | |
| parent | 668b400ff2fa5634f575e54f40ab1f0b78fcdf16 (diff) | |
feat(unstable/test): imperative test steps API (#12190)
Diffstat (limited to 'cli/tests/testdata/test/steps/ignored_steps.ts')
| -rw-r--r-- | cli/tests/testdata/test/steps/ignored_steps.ts | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/cli/tests/testdata/test/steps/ignored_steps.ts b/cli/tests/testdata/test/steps/ignored_steps.ts new file mode 100644 index 000000000..102b481fb --- /dev/null +++ b/cli/tests/testdata/test/steps/ignored_steps.ts @@ -0,0 +1,16 @@ +Deno.test("ignored step", async (t) => { + let result = await t.step({ + name: "step 1", + ignore: true, + fn: () => { + throw new Error("Fail."); + }, + }); + if (result !== false) throw new Error("Expected false."); + result = await t.step({ + name: "step 2", + ignore: false, + fn: () => {}, + }); + if (result !== true) throw new Error("Expected true."); +}); |
