This repository was archived by the owner on Aug 18, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +21
-1
lines changed
Expand file tree Collapse file tree 2 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ function parseAndAssertSame(code) {
8080 // assert.equal(esAST, babylonAST);
8181}
8282
83- describe ( "acorn -to-esprima" , function ( ) {
83+ describe ( "babylon -to-esprima" , function ( ) {
8484 describe ( "templates" , function ( ) {
8585 it ( "empty template string" , function ( ) {
8686 parseAndAssertSame ( "``" ) ;
Original file line number Diff line number Diff line change @@ -1452,6 +1452,26 @@ describe("verify", function () {
14521452 ) ;
14531453 } ) ;
14541454
1455+ it ( "new.target is not reported as undef #235" , function ( ) {
1456+ verifyAndAssertMessages (
1457+ "function foo () { return new.target }" ,
1458+ { "no-undef" : 1 } ,
1459+ [ ]
1460+ ) ;
1461+ } ) ;
1462+
1463+ it ( "decorator does not create TypeError #229" , function ( ) {
1464+ verifyAndAssertMessages ( [
1465+ "class A {" ,
1466+ " @test" ,
1467+ " f() {}" ,
1468+ "}"
1469+ ] . join ( "\n" ) ,
1470+ { "no-undef" : 1 } ,
1471+ [ "2:4 'test' is not defined. no-undef" ]
1472+ ) ;
1473+ } ) ;
1474+
14551475 // it("regex with es6 unicodeCodePointEscapes", function () {
14561476 // verifyAndAssertMessages(
14571477 // "string.replace(/[\u{0000A0}-\u{10FFFF}<>\&]/gmiu, (char) => `&#x${char.codePointAt(0).toString(16)};`);",
You can’t perform that action at this time.
0 commit comments