Skip to content

Commit

Permalink
Test for babylon regression
Browse files Browse the repository at this point in the history
  • Loading branch information
danez committed Jun 17, 2017
1 parent 945f00a commit d0c3223
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions test/non-regression.js
Original file line number Diff line number Diff line change
Expand Up @@ -1771,4 +1771,19 @@ describe("verify", () => {
);
});
});

it("flow types on class method should be visited correctly", () => {
verifyAndAssertMessages(
unpad(`
import type NodeType from 'foo';
class NodeUtils {
finishNodeAt<T : NodeType>(node: T): T { return node; }
}
new NodeUtils();
`),
{ "no-unused-vars": 1 },
[]
);
});
});

0 comments on commit d0c3223

Please sign in to comment.