Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
✨ Swap http-server for a custom server with express (front-end integr…
…ation tests)
- Loading branch information
1 parent
4780442
commit 2aaaa3b
Showing
4 changed files
with
114 additions
and
251 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { expect } from "@playwright/test"; | ||
import { interceptRPC, testWithWebSocket } from "./helpers"; | ||
|
||
const anyFileId = "c7ce0794-0992-8105-8004-38e630f7920b/c7ce0794-0992-8105-8004-38f280443849"; | ||
|
||
const setupWorkspace = async (page) => { | ||
await interceptRPC(page, "get-profile", "logged-in-user/get-profile-logged-in.json"); | ||
}; | ||
|
||
testWithWebSocket.skip("Empty file is displayed correctly", async ({ page, navigate }) => { | ||
await setupWorkspace(page); | ||
await navigate(`/#/workspace/${anyFileId}`); | ||
|
||
expect(page.getByTestId("sitemap-toolbox").getByText(/page 1/i)).toBeVisible(); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import express from "express"; | ||
import { fileURLToPath } from "url"; | ||
import path from "path"; | ||
|
||
const app = express(); | ||
const port = 3500; | ||
|
||
const staticPath = path.join(fileURLToPath(import.meta.url), "../../resources/public"); | ||
app.use(express.static(staticPath)); | ||
|
||
app.listen(port, () => { | ||
console.log(`Listening at 0.0.0.0:${port}`); | ||
}); |
Oops, something went wrong.