Skip to content

Commit 53a14d5

Browse files
committed
feat(e2e): add download test
1 parent f7c6000 commit 53a14d5

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

test/e2e/downloads.test.ts

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import * as path from "path"
2+
import { promises as fs } from "fs"
3+
import { clean } from "../utils/helpers"
4+
import { describe, test } from "./baseFixture"
5+
6+
// NOTES
7+
// Next steps are to run this test and make sure it works
8+
// gotta figure out how to only run this test, 1 worker and Chrome.
9+
describe("Downloads", true, [], {}, async () => {
10+
const testName = "downloads"
11+
test.beforeAll(async () => {
12+
await clean(testName)
13+
})
14+
15+
test("should see the 'Download...' option", async ({ codeServerPage }) => {
16+
// Setup
17+
const workspaceDir = await codeServerPage.workspaceDir
18+
const tmpFilePath = path.join(workspaceDir, "unique-file.txt")
19+
await fs.writeFile(tmpFilePath, "hello world")
20+
21+
await codeServerPage.page.waitForSelector("text=unique-file.txt")
22+
})
23+
})

0 commit comments

Comments
 (0)