Unverified Commit 9a1798b6 authored by Ray Wong's avatar Ray Wong Committed by GitHub

Fix `with-jest` and `with-jest-babel` example test snapshot failure (#46885)



fixes #46838

This PR fixes the snapshot test failure of examples `with-jest` and `with-jest-babel`.

I have tested by running tests in the files generated by these 2 commands: 

```
$ npx create-next-app@latest --example https://github.com/rayrw/next.js/tree/fix-with-jest-example-test-failure/examples/with-jest fix-snapshots-failure
$ npx create-next-app@latest --example https://github.com/rayrw/next.js/tree/fix-with-jest-example-test-failure/examples/with-jest-babel fix-snapshots-failure
```
parent 105e5b00
...@@ -86,28 +86,16 @@ exports[`renders homepage unchanged 1`] = ` ...@@ -86,28 +86,16 @@ exports[`renders homepage unchanged 1`] = `
<span <span
class="logo" class="logo"
> >
<span <img
style="box-sizing: border-box; display: inline-block; overflow: hidden; background: none; opacity: 1; border: 0px; margin: 0px; padding: 0px; position: relative; max-width: 100%;" alt="Vercel Logo"
> data-nimg="1"
<span decoding="async"
style="box-sizing: border-box; display: block; background: none; opacity: 1; border: 0px; margin: 0px; padding: 0px; max-width: 100%;" height="16"
> loading="lazy"
<img src="/vercel.svg"
alt="" style="color: transparent;"
aria-hidden="true" width="72"
src="data:image/svg+xml,%3csvg%20xmlns=%27http://www.w3.org/2000/svg%27%20version=%271.1%27%20width=%2772%27%20height=%2716%27/%3e" />
style="display: block; max-width: 100%; background: none; opacity: 1; border: 0px; margin: 0px; padding: 0px;"
/>
</span>
<img
alt="Vercel Logo"
data-nimg="intrinsic"
decoding="async"
src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"
style="position: absolute; top: 0px; left: 0px; bottom: 0px; right: 0px; box-sizing: border-box; padding: 0px; margin: auto; display: block; width: 0px; height: 0px; min-width: 100%; max-width: 100%; min-height: 100%; max-height: 100%;"
/>
<noscript />
</span>
</span> </span>
</a> </a>
</footer> </footer>
......
...@@ -86,28 +86,16 @@ exports[`renders homepage unchanged 1`] = ` ...@@ -86,28 +86,16 @@ exports[`renders homepage unchanged 1`] = `
<span <span
class="logo" class="logo"
> >
<span <img
style="box-sizing: border-box; display: inline-block; overflow: hidden; background: none; opacity: 1; border: 0px; margin: 0px; padding: 0px; position: relative; max-width: 100%;" alt="Vercel Logo"
> data-nimg="1"
<span decoding="async"
style="box-sizing: border-box; display: block; background: none; opacity: 1; border: 0px; margin: 0px; padding: 0px; max-width: 100%;" height="16"
> loading="lazy"
<img src="/vercel.svg"
alt="" style="color: transparent;"
aria-hidden="true" width="72"
src="data:image/svg+xml,%3csvg%20xmlns=%27http://www.w3.org/2000/svg%27%20version=%271.1%27%20width=%2772%27%20height=%2716%27/%3e" />
style="display: block; max-width: 100%; background: none; opacity: 1; border: 0px; margin: 0px; padding: 0px;"
/>
</span>
<img
alt="Vercel Logo"
data-nimg="intrinsic"
decoding="async"
src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"
style="position: absolute; top: 0px; left: 0px; bottom: 0px; right: 0px; box-sizing: border-box; padding: 0px; margin: auto; display: block; width: 0px; height: 0px; min-width: 100%; max-width: 100%; min-height: 100%; max-height: 100%;"
/>
<noscript />
</span>
</span> </span>
</a> </a>
</footer> </footer>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment