Skip to content

Commit

Permalink
test: no default
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewLeedham authored and nicolo-ribaudo committed May 24, 2020
1 parent 8c56e76 commit 3604bae
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/babel-preset-env/test/normalize-options.spec.js
Expand Up @@ -203,6 +203,10 @@ describe("normalize-options", () => {
expect(validateStringOption("test", "value", "default")).toBe("value");
});

it("no default returns undefined", () => {
expect(validateStringOption("test", undefined)).toBe(undefined);
});

it("array option is invalid", () => {
expect(() => {
validateStringOption("test", [], "default");
Expand Down

0 comments on commit 3604bae

Please sign in to comment.