| 1 |
// Jest Snapshot v1, https://goo.gl/fbAQLP |
| 2 |
|
| 3 |
exports[`checkDuplicateNodes should throw on duplicate AST nodes within different parent 1`] = ` |
| 4 |
"Do not reuse nodes. Use \`t.cloneNode\` (or \`t.clone\`/\`t.cloneDeep\` if using babel@6) to copy them. |
| 5 |
{ |
| 6 |
\\"type\\": \\"Identifier\\", |
| 7 |
\\"name\\": \\"ref\\" |
| 8 |
} |
| 9 |
Parent: |
| 10 |
[ |
| 11 |
{ |
| 12 |
\\"type\\": \\"VariableDeclarator\\", |
| 13 |
\\"id\\": { |
| 14 |
\\"type\\": \\"Identifier\\", |
| 15 |
\\"name\\": \\"ref\\" |
| 16 |
}, |
| 17 |
\\"init\\": null |
| 18 |
}, |
| 19 |
{ |
| 20 |
\\"type\\": \\"AssignmentExpression\\", |
| 21 |
\\"operator\\": \\"=\\", |
| 22 |
\\"left\\": { |
| 23 |
\\"type\\": \\"Identifier\\", |
| 24 |
\\"name\\": \\"ref\\" |
| 25 |
}, |
| 26 |
\\"right\\": { |
| 27 |
\\"type\\": \\"NullLiteral\\" |
| 28 |
} |
| 29 |
} |
| 30 |
]" |
| 31 |
`; |
| 32 |
|
| 33 |
exports[`checkDuplicateNodes should throw on duplicate AST nodes within same parent 1`] = ` |
| 34 |
"Do not reuse nodes. Use \`t.cloneNode\` (or \`t.clone\`/\`t.cloneDeep\` if using babel@6) to copy them. |
| 35 |
{ |
| 36 |
\\"type\\": \\"Identifier\\", |
| 37 |
\\"name\\": \\"ref\\" |
| 38 |
} |
| 39 |
Parent: |
| 40 |
[ |
| 41 |
{ |
| 42 |
\\"type\\": \\"VariableDeclarator\\", |
| 43 |
\\"id\\": { |
| 44 |
\\"type\\": \\"Identifier\\", |
| 45 |
\\"name\\": \\"ref\\" |
| 46 |
}, |
| 47 |
\\"init\\": { |
| 48 |
\\"type\\": \\"Identifier\\", |
| 49 |
\\"name\\": \\"ref\\" |
| 50 |
} |
| 51 |
}, |
| 52 |
{ |
| 53 |
\\"type\\": \\"VariableDeclarator\\", |
| 54 |
\\"id\\": { |
| 55 |
\\"type\\": \\"Identifier\\", |
| 56 |
\\"name\\": \\"ref\\" |
| 57 |
}, |
| 58 |
\\"init\\": { |
| 59 |
\\"type\\": \\"Identifier\\", |
| 60 |
\\"name\\": \\"ref\\" |
| 61 |
} |
| 62 |
} |
| 63 |
]" |
| 64 |
`; |