You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems when using swc-node/jest that newlines are potentially being double escaped as they show up in snapshot output as raw characters where they were simply interpreted as newlines under the typical jest process.
to: FAKE1-744-894-6541 x3436
- body: |-
- Thanks. We will text you when a dose is available in your area.
- Questions? hidrb.com/faq
- Share? hidrb.com/#share
+ body: >-
+ \n Thanks. We will text you when a dose is available in your area.\n
+ Questions? hidrb.com/faq\n Share? hidrb.com/#share\n
↵
The text was updated successfully, but these errors were encountered:
importdedentfrom'ts-dedent'test('dedent',()=>{consts=dedent` one two three four five six `expect(s).toMatchInlineSnapshot(`"onetwo three four fivesix"`)})
failure with swc-jest:
● dedent
expect(received).toMatchInlineSnapshot(snapshot)
Snapshot name: `dedent 1`
- Snapshot - 6
+ Received + 1
- one
- two
- three
- four
- five
- six
+ \n one\n two\n three\n four\n five\n six\n
17 | `
18 |
> 19 | expect(s).toMatchInlineSnapshot(`
| ^
20 | "one
21 | two
22 |
Here are the jest.config.js setups used to reproduce this:
It seems when using
swc-node/jest
that newlines are potentially being double escaped as they show up in snapshot output as raw characters where they were simply interpreted as newlines under the typical jest process.The text was updated successfully, but these errors were encountered: