Skip to content

Commit

Permalink
ci: add Node.js 20 in the test matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
darrachequesne committed Nov 24, 2023
1 parent 5a3eafe commit b3f0cab
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/ci.yml
Expand Up @@ -16,7 +16,9 @@ jobs:

strategy:
matrix:
node-version: [14, 16]
node-version:
- 14
- 20

steps:
- name: Checkout repository
Expand All @@ -41,10 +43,10 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v3

- name: Use Node.js 16
- name: Use Node.js 20
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20

- name: Install dependencies
run: npm ci
Expand Down
5 changes: 4 additions & 1 deletion test/connection.ts
Expand Up @@ -771,7 +771,10 @@ describe("connection", () => {
});
}

if (global.Blob && null != textBlobBuilder("xxx")) {
// Blob is available in Node.js since v18, but not yet supported by the `engine.io-parser` package
const isBrowser = typeof window !== "undefined";

if (isBrowser && global.Blob && textBlobBuilder("xxx") !== null) {
it("should send binary data (as a Blob)", () => {
return wrap((done) => {
const socket = io(BASE_URL, { forceNew: true });
Expand Down

0 comments on commit b3f0cab

Please sign in to comment.