@acala-network/chopsticks-testing 0.7.3 → 0.8.0-0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +3 -2
- package/lib/index.js +2 -1
- package/package.json +4 -3
package/lib/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ApiPromise, WsProvider } from '@polkadot/api';
|
|
2
|
+
import { StorageValues } from '@acala-network/chopsticks';
|
|
2
3
|
import { Codec } from '@polkadot/types/types';
|
|
3
4
|
import { Config } from '@acala-network/chopsticks/schema';
|
|
4
5
|
import { HexString } from '@polkadot/util/types';
|
|
5
6
|
import { Keyring } from '@polkadot/keyring';
|
|
6
|
-
import { StorageValues } from '@acala-network/chopsticks/utils/set-storage';
|
|
7
7
|
import { SubmittableExtrinsic } from '@polkadot/api-base/types';
|
|
8
8
|
export * from './check';
|
|
9
9
|
export type SetupOption = {
|
|
@@ -14,11 +14,12 @@ export type SetupOption = {
|
|
|
14
14
|
db?: string;
|
|
15
15
|
timeout?: number;
|
|
16
16
|
port?: number;
|
|
17
|
+
maxMemoryBlockCount?: number;
|
|
17
18
|
};
|
|
18
19
|
export type SetupConfig = Config & {
|
|
19
20
|
timeout?: number;
|
|
20
21
|
};
|
|
21
|
-
export declare const createConfig: ({ endpoint, blockNumber, blockHash, wasmOverride, db, timeout, port, }: SetupOption) => SetupConfig;
|
|
22
|
+
export declare const createConfig: ({ endpoint, blockNumber, blockHash, wasmOverride, db, timeout, port, maxMemoryBlockCount, }: SetupOption) => SetupConfig;
|
|
22
23
|
export declare const setupContext: (option: SetupOption) => Promise<{
|
|
23
24
|
url: string;
|
|
24
25
|
chain: import("@acala-network/chopsticks").Blockchain;
|
package/lib/index.js
CHANGED
|
@@ -20,7 +20,7 @@ const chopsticks_1 = require("@acala-network/chopsticks");
|
|
|
20
20
|
const keyring_1 = require("@polkadot/keyring");
|
|
21
21
|
const vitest_1 = require("vitest");
|
|
22
22
|
__exportStar(require("./check"), exports);
|
|
23
|
-
const createConfig = ({ endpoint, blockNumber, blockHash, wasmOverride, db, timeout, port, }) => {
|
|
23
|
+
const createConfig = ({ endpoint, blockNumber, blockHash, wasmOverride, db, timeout, port, maxMemoryBlockCount, }) => {
|
|
24
24
|
// random port if not specified
|
|
25
25
|
port = port ?? Math.floor(Math.random() * 10000) + 10000;
|
|
26
26
|
const config = {
|
|
@@ -29,6 +29,7 @@ const createConfig = ({ endpoint, blockNumber, blockHash, wasmOverride, db, time
|
|
|
29
29
|
block: blockNumber || blockHash,
|
|
30
30
|
mockSignatureHost: true,
|
|
31
31
|
'build-block-mode': chopsticks_1.BuildBlockMode.Manual,
|
|
32
|
+
'max-memory-block-count': maxMemoryBlockCount ?? 100,
|
|
32
33
|
db,
|
|
33
34
|
'wasm-override': wasmOverride,
|
|
34
35
|
timeout,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@acala-network/chopsticks-testing",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0-0",
|
|
4
4
|
"author": "Bryan Chen <xlchen1291@gmail.com>",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"scripts": {
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"build": "tsc -p ./tsconfig.json"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@acala-network/chopsticks": "0.
|
|
11
|
+
"@acala-network/chopsticks": "0.8.0-0"
|
|
12
12
|
},
|
|
13
13
|
"peerDependencies": {
|
|
14
14
|
"vitest": "^0.33.0"
|
|
@@ -32,5 +32,6 @@
|
|
|
32
32
|
"default": "./lib/*.js"
|
|
33
33
|
},
|
|
34
34
|
"./package.json": "./package.json"
|
|
35
|
-
}
|
|
35
|
+
},
|
|
36
|
+
"stableVersion": "0.7.3"
|
|
36
37
|
}
|