From abe158412c36231d6f0af3b12181526dc5c375e1 Mon Sep 17 00:00:00 2001 From: Asher Date: Mon, 10 Jun 2024 10:46:36 -0800 Subject: [PATCH 1/3] Update Node to 20.12.1 --- .node-version | 2 +- CHANGELOG.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.node-version b/.node-version index 2dbbe00e679a..bc78e9f2695e 100644 --- a/.node-version +++ b/.node-version @@ -1 +1 @@ -20.11.1 +20.12.1 diff --git a/CHANGELOG.md b/CHANGELOG.md index 0df29ba4e3a9..e81f417a9e3b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,7 +27,7 @@ Code v1.90.0 ## Changed - Updated to Code 1.90.0. -- Updated Node to 20.11.1. +- Updated Node to 20.12.1. ## Added From ccc5f8219393e3b630c9a14934f315766a219650 Mon Sep 17 00:00:00 2001 From: Asher Date: Mon, 10 Jun 2024 12:37:40 -0800 Subject: [PATCH 2/3] Refresh explorer after creating file The watcher seems to not be catching this...unsure if it is a bug yet. --- test/e2e/downloads.test.ts | 4 ++++ test/e2e/uploads.test.ts | 2 ++ 2 files changed, 6 insertions(+) diff --git a/test/e2e/downloads.test.ts b/test/e2e/downloads.test.ts index 401cc422774b..1b24b62fd4dd 100644 --- a/test/e2e/downloads.test.ts +++ b/test/e2e/downloads.test.ts @@ -14,6 +14,7 @@ describe("Downloads (enabled)", ["--disable-workspace-trust"], {}, async () => { const workspaceDir = await codeServerPage.workspaceDir const tmpFilePath = path.join(workspaceDir, "unique-file.txt") await fs.writeFile(tmpFilePath, "hello world") + await codeServerPage.executeCommandViaMenus("Refresh Explorer") // Action const fileInExplorer = await codeServerPage.page.waitForSelector("text=unique-file.txt") @@ -30,6 +31,7 @@ describe("Downloads (enabled)", ["--disable-workspace-trust"], {}, async () => { const fileName = "unique-file-save-as.txt" const tmpFilePath = path.join(workspaceDir, fileName) await fs.writeFile(tmpFilePath, "Hello World") + await codeServerPage.executeCommandViaMenus("Refresh Explorer") // Action await codeServerPage.page.waitForSelector(`text=${fileName}`) @@ -71,6 +73,7 @@ describe("Downloads (disabled)", ["--disable-workspace-trust", "--disable-file-d const workspaceDir = await codeServerPage.workspaceDir const tmpFilePath = path.join(workspaceDir, "unique-file.txt") await fs.writeFile(tmpFilePath, "Hello World") + await codeServerPage.executeCommandViaMenus("Refresh Explorer") // Action const fileInExplorer = await codeServerPage.page.waitForSelector("text=unique-file.txt") @@ -87,6 +90,7 @@ describe("Downloads (disabled)", ["--disable-workspace-trust", "--disable-file-d const fileName = "unique-file-save-as.txt" const tmpFilePath = path.join(workspaceDir, fileName) await fs.writeFile(tmpFilePath, "Hello World") + await codeServerPage.executeCommandViaMenus("Refresh Explorer") // Action await codeServerPage.page.waitForSelector(`text=${fileName}`) diff --git a/test/e2e/uploads.test.ts b/test/e2e/uploads.test.ts index 55ebea947a80..8fa1799f098f 100644 --- a/test/e2e/uploads.test.ts +++ b/test/e2e/uploads.test.ts @@ -14,6 +14,7 @@ describe("Uploads (enabled)", ["--disable-workspace-trust"], {}, () => { const workspaceDir = await codeServerPage.workspaceDir const tmpDirPath = path.join(workspaceDir, "test-directory") await fs.mkdir(tmpDirPath) + await codeServerPage.executeCommandViaMenus("Refresh Explorer") // Action const fileInExplorer = await codeServerPage.page.waitForSelector('span:has-text("test-directory")') @@ -42,6 +43,7 @@ describe("Uploads (disabled)", ["--disable-workspace-trust", "--disable-file-upl const workspaceDir = await codeServerPage.workspaceDir const tmpDirPath = path.join(workspaceDir, "test-directory") await fs.mkdir(tmpDirPath) + await codeServerPage.executeCommandViaMenus("Refresh Explorer") // Action const fileInExplorer = await codeServerPage.page.waitForSelector('span:has-text("test-directory")') From 4e7def281904477006648c380027d743afabb3c4 Mon Sep 17 00:00:00 2001 From: Asher Date: Mon, 10 Jun 2024 12:58:15 -0800 Subject: [PATCH 3/3] Update invalid JSON test Seems the verbiage has changed. --- test/unit/node/settings.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/node/settings.test.ts b/test/unit/node/settings.test.ts index 68bf51784fbd..59b28b9e3584 100644 --- a/test/unit/node/settings.test.ts +++ b/test/unit/node/settings.test.ts @@ -29,7 +29,7 @@ describe("settings", () => { const settings = new SettingsProvider(pathToMockSettingsFile) await settings.read() // This happens when we can't parse a JSON (usually error in file) - expect(logger.warn).toHaveBeenCalledWith("Unexpected token t in JSON at position 29") + expect(logger.warn).toHaveBeenCalledWith("Unexpected token 't', ...\"lloWorld:\"test\"}\" is not valid JSON") }) }) describe("with invalid settings file path", () => {