Skip to content

Commit 065d877

Browse files
authored
fix(test): allow explicit undefined for boolean test options (#18786)
Fixes #18784.
1 parent 1d447cb commit 065d877

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

cli/ops/testing.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ struct TestInfo<'s> {
100100
#[serde(rename = "fn")]
101101
function: serde_v8::Value<'s>,
102102
name: String,
103+
#[serde(default)]
103104
ignore: bool,
105+
#[serde(default)]
104106
only: bool,
105107
location: TestLocation,
106108
}

cli/tests/unit/testing_test.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,3 +147,8 @@ Deno.test(async function parentOnTextContext(t1) {
147147
});
148148
});
149149
});
150+
151+
Deno.test("explicit undefined for boolean options", {
152+
ignore: undefined,
153+
only: undefined,
154+
}, () => {});

0 commit comments

Comments
 (0)