Skip to content

Commit

Permalink
chore: run tests against node@22 (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
szuperaz authored Apr 26, 2024
1 parent 31b7126 commit 6a150d4
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cleanup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20
node-version: 22
cache: "yarn"

- name: Install Dependencies
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
test-node:
strategy:
matrix:
version: [18, 20]
version: [18, 20, 22]
runs-on: ubuntu-latest
needs: [lint]
steps:
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ The package is tested against these environments:

- Node.js@18
- Node.js@20
- Node.js@22
- Bun@1

## What is Stream?
Expand Down
4 changes: 3 additions & 1 deletion __tests__/channel.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ describe('channel API', () => {
user_id: user2.id,
});

expect(queryResponse.channels.length).toBe(0);
expect(
queryResponse.channels.find((c) => c.channel?.cid === channel.cid),
).toBe(undefined);
});

it('export', async () => {
Expand Down
2 changes: 1 addition & 1 deletion __tests__/users.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ describe('user API', () => {

const userResponse = response.users[newUser.id];

expect(userResponse.name).toBe(undefined);
expect(userResponse.name).toBeFalsy();
expect(userResponse.role).toBe('admin');
expect(userResponse.custom.color).toBe('blue');
});
Expand Down
2 changes: 1 addition & 1 deletion rollup.config.mjs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import typescript from "@rollup/plugin-typescript";
import replace from "@rollup/plugin-replace";

import pkg from "./package.json" assert { type: "json" };
import pkg from "./package.json" with { type: "json" };

const nodeConfig = {
input: "index.ts",
Expand Down

0 comments on commit 6a150d4

Please sign in to comment.