Skip to content

Commit 228e34a

Browse files
committed
feat: bump version\
\ BREAKING CHANGE: starknetjs v9
1 parent 790f926 commit 228e34a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

__tests__/contract.test.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import {
1515
byteArray,
1616
RpcError,
1717
ReceiptTx,
18+
RpcProvider,
1819
} from '../src';
1920

2021
import { contracts } from './config/fixtures';
@@ -26,7 +27,7 @@ describe('contract module', () => {
2627
let provider: ProviderInterface;
2728
let account: Account;
2829
const erc20ClassHash = hash.computeContractClassHash(contracts.Erc20OZ.sierra);
29-
const erc20CompiledClassHash = hash.computeCompiledClassHash(contracts.Erc20OZ.casm);
30+
let erc20CompiledClassHash: string;
3031
const erc20CallData = new CallData(contracts.Erc20OZ.sierra.abi);
3132
let erc20Constructor: Calldata;
3233
let erc20ConstructorParams: RawArgs;
@@ -44,6 +45,11 @@ describe('contract module', () => {
4445
owner: account.address,
4546
};
4647
erc20Constructor = erc20CallData.compile('constructor', erc20ConstructorParams);
48+
49+
erc20CompiledClassHash = hash.computeCompiledClassHash(
50+
contracts.Erc20OZ.casm,
51+
await (provider as RpcProvider).getStarknetVersion()
52+
);
4753
});
4854

4955
describe('class Contract {}', () => {

0 commit comments

Comments
 (0)