Skip to content

Commit

Permalink
Transform: Object() -> {} (+tests)
Browse files Browse the repository at this point in the history
  • Loading branch information
bfred-it committed Jul 10, 2016
1 parent fc726e3 commit 3a97a11
Showing 1 changed file with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,12 @@ describe("type-constructors-plugin", () => {
[
Object("undefined"),
Object(nulled),
Object(false)
Object(0),
Object(false),
Object(stuff())
]
`);
const expected = "[Object(\"undefined\"), Object(nulled), Object(false)];";
const expected = "[Object(\"undefined\"), Object(nulled), Object(0), Object(false), Object(stuff())];";
expect(transform(source)).toBe(expected);
});

Expand All @@ -184,10 +186,12 @@ describe("type-constructors-plugin", () => {
new Object("function"),
new Object(Symbol),
new Object(Array),
new Object(true)
new Object(true),
new Object(1),
new Object(call({ me: true }))
]
`);
const expected = "[Object(\"function\"), Object(Symbol), Object(Array), Object(true)];";
const expected = "[Object(\"function\"), Object(Symbol), Object(Array), Object(true), Object(1), Object(call({ me: true }))];";
expect(transform(source)).toBe(expected);
});

Expand Down

0 comments on commit 3a97a11

Please sign in to comment.