@midnightntwrk/wallet-sdk-testkit 0.3.0-beta.0 → 0.3.0-beta.1

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.
@@ -42,6 +42,12 @@ export const NETWORK_PRESETS = {
42
42
  indexerWsUrl: 'wss://indexer.preprod.midnight.network/api/v4/graphql/ws',
43
43
  nodeUrl: 'wss://rpc.preprod.midnight.network',
44
44
  },
45
+ stagenet: {
46
+ networkId: NetworkId.NetworkId.StageNet,
47
+ indexerHttpUrl: 'https://indexer.stagenet.shielded.tools/api/v4/graphql',
48
+ indexerWsUrl: 'wss://indexer.stagenet.shielded.tools/api/v4/graphql/ws',
49
+ nodeUrl: 'wss://rpc.stagenet.shielded.tools',
50
+ },
45
51
  };
46
52
  /**
47
53
  * Builds a {@link WalletTestEnvironment} from already-resolved endpoints. Shared by the remote factory below and the
@@ -14,22 +14,37 @@ export declare const waitForStateAfterDustRegistration: (wallet: WalletFacade, f
14
14
  export declare const waitForRegisteredTokens: (wallet: WalletFacade) => Promise<import("@midnightntwrk/wallet-sdk-facade").FacadeState>;
15
15
  export declare const waitForTxInHistory: (txHash: string, wallet: WalletFacade, ready?: (entry: WalletEntry) => boolean) => Promise<{
16
16
  readonly hash: string;
17
- readonly protocolVersion: number;
18
- readonly status: "SUCCESS" | "FAILURE" | "PARTIAL_SUCCESS";
19
- readonly identifiers?: readonly string[] | undefined;
17
+ readonly identifiers: readonly string[];
18
+ readonly protocolVersion?: number | undefined;
19
+ readonly status?: "SUCCESS" | "FAILURE" | "PARTIAL_SUCCESS" | undefined;
20
20
  readonly timestamp?: Date | undefined;
21
21
  readonly fees?: bigint | null | undefined;
22
+ readonly lifecycle: {
23
+ readonly status: "pending";
24
+ readonly submittedAt: Date;
25
+ } | {
26
+ readonly status: "finalized";
27
+ readonly finalizedBlock: {
28
+ readonly hash: string;
29
+ readonly timestamp: Date;
30
+ readonly height: number;
31
+ };
32
+ } | {
33
+ readonly status: "rejected";
34
+ readonly rejectedAt: Date;
35
+ readonly reason?: string | undefined;
36
+ };
22
37
  readonly shielded?: {
23
38
  readonly receivedCoins: readonly {
39
+ readonly value: bigint;
24
40
  readonly type: string;
25
41
  readonly nonce: string;
26
- readonly value: bigint;
27
42
  readonly mtIndex: bigint;
28
43
  }[];
29
44
  readonly spentCoins: readonly {
45
+ readonly value: bigint;
30
46
  readonly type: string;
31
47
  readonly nonce: string;
32
- readonly value: bigint;
33
48
  readonly mtIndex: bigint;
34
49
  }[];
35
50
  } | undefined;
package/dist/types.d.ts CHANGED
@@ -4,7 +4,7 @@ import { type DefaultV1Configuration as DefaultDustV1Configuration } from '@midn
4
4
  import { type DefaultProvingConfiguration } from '@midnightntwrk/wallet-sdk-capabilities/proving';
5
5
  import { type DefaultSubmissionConfiguration } from '@midnightntwrk/wallet-sdk-capabilities/submission';
6
6
  /** Networks a wallet test environment can target. */
7
- export type MidnightNetwork = 'undeployed' | 'qanet' | 'devnet' | 'preview' | 'preprod';
7
+ export type MidnightNetwork = 'undeployed' | 'qanet' | 'devnet' | 'preview' | 'preprod' | 'stagenet';
8
8
  /** A remote (already-running) network — anything other than the local testcontainers stack. */
9
9
  export type RemoteNetwork = Exclude<MidnightNetwork, 'undeployed'>;
10
10
  /**
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@midnightntwrk/wallet-sdk-testkit",
3
3
  "description": "Reusable wallet-SDK test harness: environment provisioning, wallet bootstrapping, sync waiters and tx-history assertions",
4
- "version": "0.3.0-beta.0",
4
+ "version": "0.3.0-beta.1",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "module": "./dist/index.js",
@@ -40,21 +40,21 @@
40
40
  },
41
41
  "dependencies": {
42
42
  "@midnightntwrk/ledger-v9": "1.0.0-rc.2",
43
- "@midnightntwrk/wallet-sdk-abstractions": "workspace:^",
44
- "@midnightntwrk/wallet-sdk-address-format": "workspace:^",
45
- "@midnightntwrk/wallet-sdk-capabilities": "workspace:^",
46
- "@midnightntwrk/wallet-sdk-dust-wallet": "workspace:^",
47
- "@midnightntwrk/wallet-sdk-facade": "workspace:^",
48
- "@midnightntwrk/wallet-sdk-hd": "workspace:^",
49
- "@midnightntwrk/wallet-sdk-indexer-client": "workspace:^",
50
- "@midnightntwrk/wallet-sdk-shielded": "workspace:^",
51
- "@midnightntwrk/wallet-sdk-unshielded-wallet": "workspace:^",
43
+ "@midnightntwrk/wallet-sdk-abstractions": "3.0.0-beta.0",
44
+ "@midnightntwrk/wallet-sdk-address-format": "4.0.0-beta.1",
45
+ "@midnightntwrk/wallet-sdk-capabilities": "4.0.0-beta.1",
46
+ "@midnightntwrk/wallet-sdk-dust-wallet": "5.0.0-beta.1",
47
+ "@midnightntwrk/wallet-sdk-facade": "5.0.0-beta.1",
48
+ "@midnightntwrk/wallet-sdk-hd": "3.1.0-beta.1",
49
+ "@midnightntwrk/wallet-sdk-indexer-client": "1.3.0-beta.1",
50
+ "@midnightntwrk/wallet-sdk-shielded": "4.0.0-beta.1",
51
+ "@midnightntwrk/wallet-sdk-unshielded-wallet": "4.0.0-beta.1",
52
52
  "pino": "^10.3.1",
53
53
  "pino-pretty": "^13.1.3",
54
54
  "rxjs": "^7.8.2"
55
55
  },
56
56
  "peerDependencies": {
57
- "@midnightntwrk/wallet-sdk-utilities": "workspace:^",
57
+ "@midnightntwrk/wallet-sdk-utilities": "1.2.0",
58
58
  "testcontainers": "^11.12.0",
59
59
  "vitest": "^4.1.4"
60
60
  },