Skip to content

Commit

Permalink
fix(fixture): add type to arns state fixture
Browse files Browse the repository at this point in the history
  • Loading branch information
atticusofsparta committed Feb 15, 2024
1 parent bbc2cd6 commit 5bcac32
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ export type EvaluatedContractState<ContractState> =
EvalStateResult<ContractState> & {
sortKey: string;
evaluationOptions: EvaluationOptions;
contractTxId: string;
};

/* eslint-disable @typescript-eslint/no-explicit-any */
Expand Down
12 changes: 9 additions & 3 deletions tests/fixtures/arns-service-responses.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
export const ArnsStateResponse = {
import { Source, SourceType } from 'warp-contracts';

import { EvaluatedContractState } from '../../src/types.js';

export const ArnsStateResponse: EvaluatedContractState<Record<string, any>> = {
contractTxId: 'bLAgYxAdX2Ry-nt6aH2ixgvJXbpsEYm28NgJgyqfs-U',
state: {
ticker: 'ARNS-TEST',
Expand Down Expand Up @@ -29,12 +33,14 @@ export const ArnsStateResponse = {
sortKey:
'000001301946,0000000000000,d2efe5278648460ed160e1d8a28fb86ab686e36cf14a3321d0a2b10c6851ea99',
evaluationOptions: {
sourceType: 'arweave',
sourceType: 'arweave' as SourceType,
internalWrites: true,
useKVStorage: true,
remoteStateSyncEnabled: true,
waitForConfirmation: true,
maxInteractionEvaluationTimeSeconds: 0,
throwOnInternalWriteError: true,
},
} as any,
validity: {},
errorMessages: {},
};

0 comments on commit 5bcac32

Please sign in to comment.