Skip to content

Commit 02f331d

Browse files
committed
test(package): [@onr/cloud-stream] fix tests
1 parent 32613b4 commit 02f331d

File tree

3 files changed

+9
-8
lines changed

3 files changed

+9
-8
lines changed

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@
1212
"scripts": {
1313
"start": "turbo run start --parallel --scope='!next-starter'",
1414
"dev": "turbo run dev --parallel --scope='!next-starter'",
15-
"build": "turbo run build",
16-
"storybook": "turbo run storybook",
17-
"lint": "turbo run lint --parallel",
18-
"format": "turbo run format --parallel",
15+
"build": "turbo run build --scope='!next-starter'",
16+
"storybook": "turbo run storybook --scope='!next-starter'",
17+
"lint": "turbo run lint --parallel --scope='!next-starter'",
18+
"format": "turbo run format --parallel --scope='!next-starter'",
1919
"test": "turbo run test --parallel --scope='!next-starter'",
20-
"test:ci": "turbo run test --concurrency=1",
21-
"test:watch": "yarn test --watch",
20+
"test:ci": "turbo run test --concurrency=1 --scope='!next-starter'",
21+
"test:watch": "yarn test --watch --scope='!next-starter'",
2222
"prepublishOnly": "yarn build",
2323
"postinstall": "husky install"
2424
},

packages/cloud-stream/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
"lint": "prettier -c 'src/**/*'; eslint src --ext .ts,.tsx",
3030
"format": "prettier --write 'src/**/*'; eslint src --fix --ext .ts,.tsx",
3131
"build": "tsc --build tsconfig.json",
32-
"test": "jest --coverage --passWithNoTests",
32+
"test": "jest --coverage --passWithNoTests --detectOpenHandles --forceExit",
3333
"test:watch": "yarn test --watch",
3434
"prepublishOnly": "yarn build"
3535
},

packages/cloud-stream/tests/CloudStream.test.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,8 @@ describe('CloudStream', () => {
6464

6565
describe('Subscribe extra channel', () => {
6666
it('connect the server', () => {
67-
const cloudStream = CloudStream.connect('pusher', {
67+
const mockConnector = new MockConnector();
68+
const cloudStream = CloudStream.connect(mockConnector, {
6869
channel: 'channel1',
6970
config: {
7071
appKey: 'test',

0 commit comments

Comments
 (0)