Skip to content

Commit

Permalink
Fix: Ensure allowing await as a property name (fixes eslint#5564)
Browse files Browse the repository at this point in the history
  • Loading branch information
mysticatea authored and pvamshi committed Mar 17, 2016
1 parent c39d5f2 commit d610946
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -42,7 +42,7 @@
"doctrine": "^1.2.0",
"es6-map": "^0.1.3",
"escope": "^3.6.0",
"espree": "^3.1.1",
"espree": "^3.1.2",
"estraverse": "^4.2.0",
"esutils": "^2.0.2",
"file-entry-cache": "^1.1.1",
Expand Down
8 changes: 8 additions & 0 deletions tests/lib/eslint.js
Expand Up @@ -3120,6 +3120,14 @@ describe("eslint", function() {
eslint.verify("function render() { return <div className='test'>{hello}</div> }", { parserOptions: { ecmaVersion: 6, ecmaFeatures: {jsx: true} }});
eslint.verify(eslint.getSourceCode(), { parserOptions: { ecmaVersion: 6, ecmaFeatures: {jsx: true} }});
});

it("should allow 'await' as a property name in modules", function() {
var result = eslint.verify(
"obj.await",
{parserOptions: {ecmaVersion: 6, sourceType: "module"}}
);
assert(result.length === 0);
});
});

describe("Variables and references", function() {
Expand Down

0 comments on commit d610946

Please sign in to comment.