Skip to content

Commit

Permalink
Clean up oudated comments & fixtures
Browse files Browse the repository at this point in the history
  • Loading branch information
afcapel committed Nov 17, 2023
1 parent fc1d9be commit 538764c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
4 changes: 0 additions & 4 deletions src/tests/fixtures/page_refresh.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,6 @@ <h2>Frame to be preserved</h2>
</turbo-frame>
</div>

<div id="stimulus-controller" data-controller="test">
<h3>Element with Stimulus controller</h3>
</div>

<p><a id="link" href="/src/tests/fixtures/one.html">Link to another page</a></p>

<form id="form" action="/__turbo/refresh" method="post" class="redirect">
Expand Down
4 changes: 1 addition & 3 deletions src/tests/functional/page_refresh_tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ test("uses morphing to update remote frames", async ({ page }) => {
await nextEventNamed(page, "turbo:render", { renderMethod: "morph" })
await nextBeat()

// Only the frame marked with refresh="morph" uses morphing
expect(await nextEventOnTarget(page, "remote-frame", "turbo:before-frame-morph")).toBeTruthy()
await expect(page.locator("#remote-frame")).toHaveText("Loaded morphed frame")
})
Expand All @@ -52,8 +51,7 @@ test("don't refresh frames contained in [data-turbo-permanent] elements", async
await nextEventNamed(page, "turbo:render", { renderMethod: "morph" })
await nextBeat()

// Only the frame marked with refresh="morph" uses morphing
expect(await noNextEventOnTarget(page, "refresh-reload", "turbo:before-frame-morph")).toBeTruthy()
expect(await noNextEventOnTarget(page, "remote-permanent-frame", "turbo:before-frame-morph")).toBeTruthy()
})

test("remote frames are excluded from full page morphing", async ({ page }) => {
Expand Down

0 comments on commit 538764c

Please sign in to comment.