Fix fullstack serialization order for adjacent components (#4600)
* fix serialization order * add regression test * split out test into a seperate package * revert logging * change order * opinions on structure * small wait in hydration order test --------- Co-authored-by: Jonathan Kelley <jkelleyrtp@gmail.com>
This commit is contained in:
1 parent
ecec70f5e8
commit
12fab0f9f7
8 files changed
+215
-15
No files matched your search
@@ -0,0 +1,17 @@
|
||||
// @ts-check
|
||||
const { test, expect } = require("@playwright/test");
|
||||
|
||||
test("hydration", async ({ page }) => {
|
||||
await page.goto("http://localhost:7979");
|
||||
|
||||
// give time for the page to load and hydrate
|
||||
await page.waitForTimeout(2000);
|
||||
|
||||
// Expect the page to contain a button
|
||||
const button = page.locator("#counter");
|
||||
await expect(button).toContainText("Count 0");
|
||||
|
||||
// Hydration should succeed and clicking the button should increase the count
|
||||
await button.click();
|
||||
await expect(button).toContainText("Count 1");
|
||||
});
|
||||
Reference in new issue
Block a user