Skip to content

Commit 14901e2

Browse files
committed
chore: fix tests
1 parent 225c06c commit 14901e2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/options.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ describe("options", () => {
166166
process.argv.push("--test1");
167167
process.argv.push("value");
168168
const options = createOptions(testInjector);
169-
options.validateOptions({ test1: { type: OptionType.String } });
169+
options.validateOptions({ test1: { type: OptionType.String, hasSensitiveValue: false } });
170170
process.argv.pop();
171171
process.argv.pop();
172172
assert.isFalse(isExecutionStopped);
@@ -175,7 +175,7 @@ describe("options", () => {
175175
it("does not break execution when valid commandSpecificOptions are passed and user specifies globally valid option", () => {
176176
const options = createOptions(testInjector);
177177
process.argv.push("--version");
178-
options.validateOptions({ test1: { type: OptionType.String } });
178+
options.validateOptions({ test1: { type: OptionType.String, hasSensitiveValue: false } });
179179
process.argv.pop();
180180
assert.isFalse(isExecutionStopped);
181181
});
@@ -253,7 +253,7 @@ describe("options", () => {
253253
it("does not break execution when dashed option with two dashes is passed", () => {
254254
process.argv.push("--special-dashed-v");
255255
const options = createOptions(testInjector);
256-
options.validateOptions({ specialDashedV: { type: OptionType.Boolean } });
256+
options.validateOptions({ specialDashedV: { type: OptionType.Boolean, hasSensitiveValue: false } });
257257
process.argv.pop();
258258
assert.isFalse(isExecutionStopped, "Dashed options should be validated in specific way. Make sure validation allows yargs specific behavior:" +
259259
"Dashed options (special-dashed-v) are added to yargs.argv in two ways: special-dashed-v and specialDashedV");

0 commit comments

Comments
 (0)