Skip to content

Commit

Permalink
Fix node tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ibc committed Dec 12, 2023
1 parent d7a038d commit 712c930
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions node/src/tests/test-DataConsumer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,8 @@ test('transport.consumeData() succeeds', async () =>
expect(dataConsumer1.label).toBe('foo');
expect(dataConsumer1.protocol).toBe('bar');
expect(dataConsumer1.paused).toBe(false);
expect(dataConsumer1.subchannels.sort()).toEqual([ 0, 1, 2, 100, 65535 ]);
expect(dataConsumer1.subchannels.sort((a, b) => a - b))
.toEqual([ 0, 1, 2, 100, 65535 ]);
expect(dataConsumer1.appData).toEqual({ baz: 'LOL' });

const dump = await router.dump();
Expand Down Expand Up @@ -134,7 +135,8 @@ test('dataConsumer.setSubchannels() succeeds', async () =>
{
await dataConsumer1.setSubchannels([ 999, 999, 998, 65536 ]);

expect(dataConsumer1.subchannels.sort()).toEqual([ 0, 998, 999 ]);
expect(dataConsumer1.subchannels.sort((a, b) => a - b))
.toEqual([ 0, 998, 999 ]);
}, 2000);

test('transport.consumeData() on a DirectTransport succeeds', async () =>
Expand Down

0 comments on commit 712c930

Please sign in to comment.