use another approach for typecasting

This commit is contained in:
weboko 2023-01-24 00:25:33 +01:00
parent 7263c47ddf
commit 3dd8758027
No known key found for this signature in database

View File

@ -18,9 +18,9 @@ describe("RLN Contract abstraction", () => {
provider: voidSigner,
});
rlnContract["_contract" as any] = {
rlnContract["_contract"] = {
queryFilter: () => Promise.resolve([mockEvent()]),
};
} as unknown as ethers.Contract;
chai.spy.on(rlnContract, "contract.queryFilter");
await rlnContract.fetchMembers(rlnInstance);
@ -39,9 +39,9 @@ describe("RLN Contract abstraction", () => {
provider: voidSigner,
});
rlnContract["_contract" as any] = {
rlnContract["_contract"] = {
MEMBERSHIP_DEPOSIT: () => Promise.resolve(1),
};
} as unknown as ethers.Contract;
chai.spy.on(rlnContract, "contract.MEMBERSHIP_DEPOSIT");
const contractSpy = chai.spy.on(rlnContract, "contract.register");