Skip to content

fix: revert CI change + fix broken tests #4306

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Oct 4, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ jobs:
run: yarn lint
if: success()

- name: Run code-server unit tests
run: yarn test:unit
if: success()

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm guessing this was removed by accident but it should be here and we need it before uploading coverage to Codecov (it outputs coverage information).

- name: Upload coverage report to Codecov
run: yarn coverage
if: success()
Expand Down Expand Up @@ -404,9 +408,6 @@ jobs:
rm -r node_modules/playwright
yarn install --check-files

- name: Run end-to-end tests
run: yarn test:unit

Comment on lines -407 to -409
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to run unit tests twice

- name: Run end-to-end tests
run: yarn test:e2e

Expand Down
2 changes: 1 addition & 1 deletion src/node/routes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ export const register = async (
}

server.on("close", () => {
vscode.vscodeServer.close()
vscode?.vscodeServer.close()
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This prevents us trying to call vscodeServer.close() on undefined

})

app.use(() => {
Expand Down
2 changes: 1 addition & 1 deletion test/unit/node/routes/static.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import * as integration from "../../../utils/integration"

const NOT_FOUND = {
code: 404,
message: "not found",
message: "Not Found",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Change needed to make test pass (casing shouldn't matter). I was going to use .toMatch(/string/) but this was quicker

}

describe("/_static", () => {
Expand Down