-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(ast-spec): update
@babel/parser
and spapshots (#6266)
* chore: update `@babel/parser` * chore: update snapshots for `@babel/parser` Co-authored-by: Josh Goldberg <git@joshuakgoldberg.com>
- Loading branch information
1 parent
d562244
commit d64a9b9
Showing
35 changed files
with
1,758 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
...lement/AccessorProperty/fixtures/_error_/modifier-declare/snapshots/1-TSESTree-Error.shot
This file was deleted.
Oops, something went wrong.
3 changes: 0 additions & 3 deletions
3
...c/element/AccessorProperty/fixtures/_error_/modifier-declare/snapshots/2-Babel-Error.shot
This file was deleted.
Oops, something went wrong.
3 changes: 0 additions & 3 deletions
3
...ement/AccessorProperty/fixtures/_error_/modifier-declare/snapshots/3-Alignment-Error.shot
This file was deleted.
Oops, something went wrong.
3 changes: 0 additions & 3 deletions
3
...ges/ast-spec/src/element/AccessorProperty/fixtures/modifier-abstract-with-value/config.ts
This file was deleted.
Oops, something went wrong.
99 changes: 99 additions & 0 deletions
99
...element/AccessorProperty/fixtures/modifier-abstract-with-value/snapshots/3-Babel-AST.shot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`AST Fixtures element AccessorProperty modifier-abstract-with-value Babel - AST 1`] = ` | ||
Program { | ||
type: "Program", | ||
body: Array [ | ||
ClassDeclaration { | ||
type: "ClassDeclaration", | ||
abstract: true, | ||
body: ClassBody { | ||
type: "ClassBody", | ||
body: Array [ | ||
ClassAccessorProperty { | ||
type: "ClassAccessorProperty", | ||
abstract: true, | ||
computed: false, | ||
key: Identifier { | ||
type: "Identifier", | ||
name: "foo", | ||
range: [41, 44], | ||
loc: { | ||
start: { column: 20, line: 2 }, | ||
end: { column: 23, line: 2 }, | ||
}, | ||
}, | ||
static: false, | ||
typeAnnotation: TSTypeAnnotation { | ||
type: "TSTypeAnnotation", | ||
typeAnnotation: TSNumberKeyword { | ||
type: "TSNumberKeyword", | ||
range: [46, 52], | ||
loc: { | ||
start: { column: 25, line: 2 }, | ||
end: { column: 31, line: 2 }, | ||
}, | ||
}, | ||
range: [44, 52], | ||
loc: { | ||
start: { column: 23, line: 2 }, | ||
end: { column: 31, line: 2 }, | ||
}, | ||
}, | ||
value: Literal { | ||
type: "Literal", | ||
raw: "1", | ||
value: 1, | ||
range: [55, 56], | ||
loc: { | ||
start: { column: 34, line: 2 }, | ||
end: { column: 35, line: 2 }, | ||
}, | ||
}, | ||
range: [23, 57], | ||
loc: { | ||
start: { column: 2, line: 2 }, | ||
end: { column: 36, line: 2 }, | ||
}, | ||
}, | ||
], | ||
range: [19, 59], | ||
loc: { | ||
start: { column: 19, line: 1 }, | ||
end: { column: 1, line: 3 }, | ||
}, | ||
}, | ||
id: Identifier { | ||
type: "Identifier", | ||
name: "Foo", | ||
range: [15, 18], | ||
loc: { | ||
start: { column: 15, line: 1 }, | ||
end: { column: 18, line: 1 }, | ||
}, | ||
}, | ||
superClass: null, | ||
range: [0, 59], | ||
loc: { | ||
start: { column: 0, line: 1 }, | ||
end: { column: 1, line: 3 }, | ||
}, | ||
}, | ||
], | ||
sourceType: "script", | ||
range: [0, 60], | ||
loc: { | ||
start: { column: 0, line: 1 }, | ||
end: { column: 0, line: 4 }, | ||
}, | ||
} | ||
`; |
136 changes: 136 additions & 0 deletions
136
...ment/AccessorProperty/fixtures/modifier-abstract-with-value/snapshots/4-Babel-Tokens.shot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`AST Fixtures element AccessorProperty modifier-abstract-with-value Babel - Tokens 1`] = ` | ||
Array [ | ||
Identifier { | ||
type: "Identifier", | ||
value: "abstract", | ||
range: [0, 8], | ||
loc: { | ||
start: { column: 0, line: 1 }, | ||
end: { column: 8, line: 1 }, | ||
}, | ||
}, | ||
Keyword { | ||
type: "Keyword", | ||
value: "class", | ||
range: [9, 14], | ||
loc: { | ||
start: { column: 9, line: 1 }, | ||
end: { column: 14, line: 1 }, | ||
}, | ||
}, | ||
Identifier { | ||
type: "Identifier", | ||
value: "Foo", | ||
range: [15, 18], | ||
loc: { | ||
start: { column: 15, line: 1 }, | ||
end: { column: 18, line: 1 }, | ||
}, | ||
}, | ||
Punctuator { | ||
type: "Punctuator", | ||
value: "{", | ||
range: [19, 20], | ||
loc: { | ||
start: { column: 19, line: 1 }, | ||
end: { column: 20, line: 1 }, | ||
}, | ||
}, | ||
Identifier { | ||
type: "Identifier", | ||
value: "abstract", | ||
range: [23, 31], | ||
loc: { | ||
start: { column: 2, line: 2 }, | ||
end: { column: 10, line: 2 }, | ||
}, | ||
}, | ||
Identifier { | ||
type: "Identifier", | ||
value: "accessor", | ||
range: [32, 40], | ||
loc: { | ||
start: { column: 11, line: 2 }, | ||
end: { column: 19, line: 2 }, | ||
}, | ||
}, | ||
Identifier { | ||
type: "Identifier", | ||
value: "foo", | ||
range: [41, 44], | ||
loc: { | ||
start: { column: 20, line: 2 }, | ||
end: { column: 23, line: 2 }, | ||
}, | ||
}, | ||
Punctuator { | ||
type: "Punctuator", | ||
value: ":", | ||
range: [44, 45], | ||
loc: { | ||
start: { column: 23, line: 2 }, | ||
end: { column: 24, line: 2 }, | ||
}, | ||
}, | ||
Identifier { | ||
type: "Identifier", | ||
value: "number", | ||
range: [46, 52], | ||
loc: { | ||
start: { column: 25, line: 2 }, | ||
end: { column: 31, line: 2 }, | ||
}, | ||
}, | ||
Punctuator { | ||
type: "Punctuator", | ||
value: "=", | ||
range: [53, 54], | ||
loc: { | ||
start: { column: 32, line: 2 }, | ||
end: { column: 33, line: 2 }, | ||
}, | ||
}, | ||
Numeric { | ||
type: "Numeric", | ||
value: "1", | ||
range: [55, 56], | ||
loc: { | ||
start: { column: 34, line: 2 }, | ||
end: { column: 35, line: 2 }, | ||
}, | ||
}, | ||
Punctuator { | ||
type: "Punctuator", | ||
value: ";", | ||
range: [56, 57], | ||
loc: { | ||
start: { column: 35, line: 2 }, | ||
end: { column: 36, line: 2 }, | ||
}, | ||
}, | ||
Punctuator { | ||
type: "Punctuator", | ||
value: "}", | ||
range: [58, 59], | ||
loc: { | ||
start: { column: 0, line: 3 }, | ||
end: { column: 1, line: 3 }, | ||
}, | ||
}, | ||
] | ||
`; |
108 changes: 108 additions & 0 deletions
108
...AccessorProperty/fixtures/modifier-abstract-with-value/snapshots/5-AST-Alignment-AST.shot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`AST Fixtures element AccessorProperty modifier-abstract-with-value AST Alignment - AST 1`] = ` | ||
"Snapshot Diff: | ||
- TSESTree | ||
+ Babel | ||
Program { | ||
type: 'Program', | ||
body: Array [ | ||
ClassDeclaration { | ||
type: 'ClassDeclaration', | ||
abstract: true, | ||
body: ClassBody { | ||
type: 'ClassBody', | ||
body: Array [ | ||
- TSAbstractAccessorProperty { | ||
- type: 'TSAbstractAccessorProperty', | ||
+ ClassAccessorProperty { | ||
+ type: 'ClassAccessorProperty', | ||
+ abstract: true, | ||
computed: false, | ||
- declare: false, | ||
key: Identifier { | ||
type: 'Identifier', | ||
name: 'foo', | ||
range: [41, 44], | ||
loc: { | ||
start: { column: 20, line: 2 }, | ||
end: { column: 23, line: 2 }, | ||
}, | ||
}, | ||
- override: false, | ||
static: false, | ||
typeAnnotation: TSTypeAnnotation { | ||
type: 'TSTypeAnnotation', | ||
typeAnnotation: TSNumberKeyword { | ||
type: 'TSNumberKeyword', | ||
range: [46, 52], | ||
loc: { | ||
start: { column: 25, line: 2 }, | ||
end: { column: 31, line: 2 }, | ||
}, | ||
}, | ||
range: [44, 52], | ||
loc: { | ||
start: { column: 23, line: 2 }, | ||
end: { column: 31, line: 2 }, | ||
}, | ||
}, | ||
- value: null, | ||
+ value: Literal { | ||
+ type: 'Literal', | ||
+ raw: '1', | ||
+ value: 1, | ||
+ | ||
+ range: [55, 56], | ||
+ loc: { | ||
+ start: { column: 34, line: 2 }, | ||
+ end: { column: 35, line: 2 }, | ||
+ }, | ||
+ }, | ||
range: [23, 57], | ||
loc: { | ||
start: { column: 2, line: 2 }, | ||
end: { column: 36, line: 2 }, | ||
}, | ||
}, | ||
], | ||
range: [19, 59], | ||
loc: { | ||
start: { column: 19, line: 1 }, | ||
end: { column: 1, line: 3 }, | ||
}, | ||
}, | ||
id: Identifier { | ||
type: 'Identifier', | ||
name: 'Foo', | ||
range: [15, 18], | ||
loc: { | ||
start: { column: 15, line: 1 }, | ||
end: { column: 18, line: 1 }, | ||
}, | ||
}, | ||
superClass: null, | ||
range: [0, 59], | ||
loc: { | ||
start: { column: 0, line: 1 }, | ||
end: { column: 1, line: 3 }, | ||
}, | ||
}, | ||
], | ||
sourceType: 'script', | ||
range: [0, 60], | ||
loc: { | ||
start: { column: 0, line: 1 }, | ||
end: { column: 0, line: 4 }, | ||
}, | ||
}" | ||
`; |
5 changes: 4 additions & 1 deletion
5
...t-with-value/snapshots/3-Babel-Error.shot → ...lue/snapshots/6-AST-Alignment-Tokens.shot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`AST Fixtures element AccessorProperty modifier-abstract-with-value Babel - Error 1`] = `[SyntaxError: Missing semicolon. (2:23)]`; | ||
exports[`AST Fixtures element AccessorProperty modifier-abstract-with-value AST Alignment - Token 1`] = ` | ||
"Snapshot Diff: | ||
Compared values have no visual difference." | ||
`; |
3 changes: 0 additions & 3 deletions
3
packages/ast-spec/src/element/AccessorProperty/fixtures/modifier-abstract/config.ts
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.