-
Notifications
You must be signed in to change notification settings - Fork 759
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
client: migrate tests to vite (#2797)
* client: migrate tests to vite * client: update test scripts * client: fix rpc engine tests * client: fix rpc engine tests * client: remove unnecessary stringification * client: fix more rpc tests * client: misc test fixes * client: fix ci script still using tape * Rename libp2p tests to avoid vitest running them * fix instanceof tests * Update vitest.config so that test:CLI runs * Update vitest.config so that test:CLI runs * Fixes for client.spec.ts * Fix error in sender.spec.ts * Fix test formatting rlpxserver.spec.ts * Update unit test config, randomize rpc port * test fixes * more test fixes * Fix engine tests * Partial test fixes * Fix merge integration test * fix fcu hex handling * Add timeouts and fix lightsync * Various test and type fixes * fix txpool tests * correct bytes2hex import * Fix lightethereumservice tests * client: fix lesprotocol test * Fix most full ethereum service tests * Fix fullethereumservice test * "Fix" flow control test * Fix rlxppeer test * client: fix lightsync integration test timeouts * client: update client ci * client: increase timeout for some tests * client: remove only from flowcontrol test * client: more test fixes * client: increase timeout for miner * client: increase timeout for miner * client: increase more timeouts and fix missing it statement * fix integration tests * fix lint rules * fix npm script * Fix lint file extension * Fix lint config, again * File path fix --------- Co-authored-by: acolytec3 <17355484+acolytec3@users.noreply.github.com> Co-authored-by: ScottyPoi <scott.simpson@ethereum.org> Co-authored-by: Scotty <66335769+ScottyPoi@users.noreply.github.com> Co-authored-by: Holger Drewes <Holger.Drewes@gmail.com>
- Loading branch information
1 parent
6b23892
commit 8946609
Showing
118 changed files
with
7,436 additions
and
7,357 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
19 changes: 0 additions & 19 deletions
19
packages/client/libp2pBrowserBuild/net/test/libp2pnode.spec.ts
This file was deleted.
Oops, something went wrong.
17 changes: 17 additions & 0 deletions
17
packages/client/libp2pBrowserBuild/net/test/libp2pnode.spec.ts.old
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { assert, describe, it } from 'vitest' | ||
import * as td from 'testdouble' | ||
|
||
describe('[Libp2pNode]', async () => { | ||
td.replace('libp2p') | ||
const { Libp2pNode } = await import('../peer/libp2pnode') | ||
|
||
it('should be a libp2p bundle', () => { | ||
const peerId = td.object('PeerId') as any | ||
const node = new Libp2pNode({ peerId }) | ||
assert.equal(node.constructor.name, Libp2pNode.name, 'is libp2p bundle') | ||
}) | ||
|
||
it('should reset td', () => { | ||
td.reset() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.