Skip to content

Commit 1515feb

Browse files
authored
fix: build issues with newer dep versions (#167)
* fix: hardhat config * fix: assert issue
1 parent 0da77e7 commit 1515feb

File tree

4 files changed

+13
-13
lines changed

4 files changed

+13
-13
lines changed

hardhat.config.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,13 +69,13 @@ const config: HardhatUserConfig = {
6969
/**
7070
* Ethereum
7171
*/
72-
mainnet: ETHERSCAN_API_KEY,
73-
goerli: ETHERSCAN_API_KEY,
72+
mainnet: ETHERSCAN_API_KEY!,
73+
goerli: ETHERSCAN_API_KEY!,
7474
/**
7575
* Polygon
7676
*/
77-
polygon: POLYGONSCAN_API_KEY,
78-
polygonMumbai: POLYGONSCAN_API_KEY,
77+
polygon: POLYGONSCAN_API_KEY!,
78+
polygonMumbai: POLYGONSCAN_API_KEY!,
7979
},
8080
},
8181
networks: {

test/SigHelper.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ describe("SigHelper", async () => {
6969

7070
it("should cancel successfully", async () => {
7171
const initStatus = await sigHelperMock.cancelled(fakeHash);
72-
assert(!initStatus, "Initial status should be false");
72+
assert.isOk(!initStatus, "Initial status should be false");
7373

7474
await sigHelperMock.cancelHashInternal(fakeHash);
7575

@@ -81,7 +81,7 @@ describe("SigHelper", async () => {
8181
it("should not cancel an already cancelled hash", async () => {
8282
await sigHelperMock.cancelHashInternal(fakeHash);
8383
const initStatus = await sigHelperMock.cancelled(fakeHash);
84-
assert(initStatus, "Initial status should be true");
84+
assert.isOk(initStatus, "Initial status should be true");
8585

8686
const tx = sigHelperMock.cancelHashInternal(fakeHash);
8787

test/TitleEscrowSignable.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@ describe("TitleEscrowSignable", async () => {
339339
const [, invalidNominee] = users.others;
340340
await titleEscrowContractAsBeneficiary.nominate(invalidNominee.address);
341341
const onChainNominee = await titleEscrowContract.nominee();
342-
assert(onChainNominee === invalidNominee.address, "Wrong on-chain nominee");
342+
assert.isOk(onChainNominee === invalidNominee.address, "Wrong on-chain nominee");
343343

344344
const tx = titleEscrowContractAsBeneficiary.transferBeneficiaryWithSig(endorsement, sig);
345345

@@ -396,7 +396,7 @@ describe("TitleEscrowSignable", async () => {
396396
it("should transfer beneficiary successfully if on-chain nominee is same as endorsed nominee", async () => {
397397
await titleEscrowContractAsBeneficiary.nominate(nominee.address);
398398
const onChainNominee = await titleEscrowContract.nominee();
399-
assert(onChainNominee === nominee.address, "On-chain nominee is different from endorsed nominee");
399+
assert.isOk(onChainNominee === nominee.address, "On-chain nominee is different from endorsed nominee");
400400

401401
await titleEscrowContractAsBeneficiary.transferBeneficiaryWithSig(endorsement, sig);
402402
const res = await titleEscrowContract.beneficiary();
@@ -416,7 +416,7 @@ describe("TitleEscrowSignable", async () => {
416416
it("should revert if Beneficiary Transfer is cancelled", async () => {
417417
await titleEscrowContract.connect(users.holder).cancelBeneficiaryTransfer(endorsement);
418418
const cancelStatus = await titleEscrowContract.cancelled(hashStruct);
419-
assert(cancelStatus, "Beneficiary Transfer is not cancelled");
419+
assert.isOk(cancelStatus, "Beneficiary Transfer is not cancelled");
420420

421421
const tx = titleEscrowContractAsBeneficiary.transferBeneficiaryWithSig(endorsement, sig);
422422

@@ -444,7 +444,7 @@ describe("TitleEscrowSignable", async () => {
444444

445445
it("should add correct hash to cancel", async () => {
446446
const initStatus = await titleEscrowContract.cancelled(hashStruct);
447-
assert(!initStatus, "Initial cancel status should be false");
447+
assert.isOk(!initStatus, "Initial cancel status should be false");
448448

449449
await titleEscrowContractAsEndorsingHolder.cancelBeneficiaryTransfer(endorsement);
450450

test/token/SBTUpgradeable.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ describe("SBTUpgradeable", async () => {
9595

9696
it("should revert when token ID exists", async () => {
9797
const exists = await mockSbtContract.existsInternal(tokenId);
98-
assert(exists, "Token already exists");
98+
assert.isOk(exists, "Token already exists");
9999

100100
const tx = mockSbtContract.safeMintInternal(recipient, tokenId);
101101

@@ -104,7 +104,7 @@ describe("SBTUpgradeable", async () => {
104104

105105
it("should increase balance by one", async () => {
106106
const balance = await mockSbtContract.balanceOf(recipient);
107-
assert(balance.eq(1), "Balance should be 1");
107+
assert.isOk(balance.eq(1), "Balance should be 1");
108108

109109
await mockSbtContract.safeMintInternal(recipient, faker.finance.ethereumAddress());
110110
const newBalance = await mockSbtContract.balanceOf(recipient);
@@ -211,7 +211,7 @@ describe("SBTUpgradeable", async () => {
211211
await mockSbtContract.safeMintInternal(recipient, faker.datatype.hexaDecimal(64));
212212

213213
const balance = await mockSbtContract.balanceOf(recipient);
214-
assert(balance.eq(2), "Balance should be 2");
214+
assert.isOk(balance.eq(2), "Balance should be 2");
215215

216216
burnTx = await mockSbtContract.burn(tokenId);
217217
});

0 commit comments

Comments
 (0)