Skip to content

Commit

Permalink
Merge pull request #110 from 1inch/fix/fix-zksync-tests-temp
Browse files Browse the repository at this point in the history
Label addresses only for non-zksync test runs
  • Loading branch information
byshape authored Aug 30, 2024
2 parents 13f7074 + 81458b2 commit fcb7610
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 29 deletions.
44 changes: 22 additions & 22 deletions .gas-snapshot
Original file line number Diff line number Diff line change
Expand Up @@ -10,32 +10,32 @@ EscrowTest:test_CancelDst() (gas: 116076)
EscrowTest:test_CancelDstDifferentTarget() (gas: 143334)
EscrowTest:test_CancelDstWithNativeToken() (gas: 93670)
EscrowTest:test_CancelPublicSrc() (gas: 170900)
EscrowTest:test_CancelResolverSrc() (gas: 168607)
EscrowTest:test_CancelResolverSrc() (gas: 168624)
EscrowTest:test_CancelResolverSrcReceiver() (gas: 179361)
EscrowTest:test_NoAnyoneCancelDuringResolverCancelSrc() (gas: 163856)
EscrowTest:test_NoCallsWithInvalidImmutables() (gas: 286518)
EscrowTest:test_NoAnyoneCancelDuringResolverCancelSrc() (gas: 163836)
EscrowTest:test_NoCallsWithInvalidImmutables() (gas: 286516)
EscrowTest:test_NoCancelByAnyoneDst() (gas: 121726)
EscrowTest:test_NoCancelDuringWithdrawalDst() (gas: 121486)
EscrowTest:test_NoCancelDuringWithdrawalSrc() (gas: 164001)
EscrowTest:test_NoCancelDuringWithdrawalSrc() (gas: 163959)
EscrowTest:test_NoFailedNativeTokenTransferCancelSrc() (gas: 216919)
EscrowTest:test_NoFailedNativeTokenTransferWithdrawalDst() (gas: 192056)
EscrowTest:test_NoFailedNativeTokenTransferWithdrawalDstNative() (gas: 84157)
EscrowTest:test_NoFailedNativeTokenTransferWithdrawalSrc() (gas: 349820)
EscrowTest:test_NoFailedNativeTokenTransferWithdrawalSrc() (gas: 349798)
EscrowTest:test_NoPublicCallsByAnyone() (gas: 287575)
EscrowTest:test_NoPublicCancelDuringPrivateCancellationSrc() (gas: 168572)
EscrowTest:test_NoPublicCancelDuringPrivateCancellationSrc() (gas: 168592)
EscrowTest:test_NoPublicWithdrawOutsideOfAllowedPeriodDst() (gas: 137737)
EscrowTest:test_NoPublicWithdrawalOutsideOfAllowedPeriodSrc() (gas: 179920)
EscrowTest:test_NoPublicWithdrawalOutsideOfAllowedPeriodSrc() (gas: 179922)
EscrowTest:test_NoRescueFundsByAnyoneDst() (gas: 176333)
EscrowTest:test_NoRescueFundsByAnyoneSrc() (gas: 209079)
EscrowTest:test_NoRescueFundsEarlierDst() (gas: 175721)
EscrowTest:test_NoRescueFundsEarlierSrc() (gas: 208959)
EscrowTest:test_NoWithdrawalByAnyoneSrc() (gas: 160853)
EscrowTest:test_NoRescueFundsEarlierSrc() (gas: 209019)
EscrowTest:test_NoWithdrawalByAnyoneSrc() (gas: 160873)
EscrowTest:test_NoWithdrawalByNonResolverDst() (gas: 121439)
EscrowTest:test_NoWithdrawalOutsideOfAllowedPeriodDst() (gas: 126326)
EscrowTest:test_NoWithdrawalOutsideOfAllowedPeriodSrc() (gas: 169627)
EscrowTest:test_NoWithdrawalOutsideOfAllowedPeriodSrc() (gas: 169636)
EscrowTest:test_NoWithdrawalWithWrongSecretDst() (gas: 122798)
EscrowTest:test_NoWithdrawalWithWrongSecretSrc() (gas: 164448)
EscrowTest:test_PublicWithdrawSrc() (gas: 187154)
EscrowTest:test_NoWithdrawalWithWrongSecretSrc() (gas: 164478)
EscrowTest:test_PublicWithdrawSrc() (gas: 187170)
EscrowTest:test_RescueFundsDst() (gas: 158237)
EscrowTest:test_RescueFundsDstNative() (gas: 186700)
EscrowTest:test_RescueFundsSrc() (gas: 195445)
Expand All @@ -50,28 +50,28 @@ IntegrationEscrowFactoryTest:test_DeployCloneForMakerNonWhitelistedResolverInt()
IntegrationEscrowFactoryTest:test_NoInsufficientBalanceDeploymentForMakerInt() (gas: 341345)
IntegrationEscrowFactoryTest:test_NoResolverReentrancy() (gas: 2065268)
IntegrationResolverMockTest:test_MockCancelDst() (gas: 157134)
IntegrationResolverMockTest:test_MockCancelSrc() (gas: 354038)
IntegrationResolverMockTest:test_MockCancelSrc() (gas: 354053)
IntegrationResolverMockTest:test_MockDeployDst() (gas: 151470)
IntegrationResolverMockTest:test_MockDeploySrc() (gas: 364984)
IntegrationResolverMockTest:test_MockPublicCancelSrc() (gas: 397961)
IntegrationResolverMockTest:test_MockPublicCancelSrc() (gas: 398004)
IntegrationResolverMockTest:test_MockPublicWithdrawDst() (gas: 170216)
IntegrationResolverMockTest:test_MockRescueFundsDst() (gas: 161053)
IntegrationResolverMockTest:test_MockRescueFundsSrc() (gas: 382664)
IntegrationResolverMockTest:test_MockWithdrawDst() (gas: 182875)
IntegrationResolverMockTest:test_MockWithdrawToSrc() (gas: 354920)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillAllExtra() (gas: 923635)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillAllFromLast() (gas: 922417)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillAllTwoFills() (gas: 922239)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillFirst() (gas: 707710)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillFirstTwoFills() (gas: 933041)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillLast() (gas: 707378)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillAllTwoFills() (gas: 922238)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillFirst() (gas: 707719)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillFirstTwoFills() (gas: 933063)
MerkleStorageInvalidatorIntTest:test_MultipleFillsFillLast() (gas: 707290)
MerkleStorageInvalidatorIntTest:test_MultipleFillsNoDeploymentWithoutValidation() (gas: 301424)
MerkleStorageInvalidatorIntTest:test_MultipleFillsNoReuseOfSecrets() (gas: 1068098)
MerkleStorageInvalidatorIntTest:test_MultipleFillsNoSecondDeploymentWithTheSameIndex() (gas: 786092)
MerkleStorageInvalidatorIntTest:test_MultipleFillsNoReuseOfSecrets() (gas: 1069309)
MerkleStorageInvalidatorIntTest:test_MultipleFillsNoSecondDeploymentWithTheSameIndex() (gas: 786059)
MerkleStorageInvalidatorIntTest:test_MultipleFillsOddDivision() (gas: 444873)
MerkleStorageInvalidatorIntTest:test_MultipleFillsOneFill() (gas: 707726)
MerkleStorageInvalidatorIntTest:test_MultipleFillsTwoFills() (gas: 921505)
MerkleStorageInvalidatorTest:test_ShortenedProofIsNotValid() (gas: 230686)
MerkleStorageInvalidatorIntTest:test_MultipleFillsTwoFills() (gas: 921521)
MerkleStorageInvalidatorTest:test_ShortenedProofIsNotValid() (gas: 230633)
TimelocksLibTest:test_NoTimelocksOverflow() (gas: 193707)
TimelocksLibTest:test_getStartTimestamps() (gas: 16207)
TimelocksLibTest:test_setDeployedAt() (gas: 5741)
19 changes: 12 additions & 7 deletions test/utils/BaseSetup.sol
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,13 @@ contract BaseSetup is Test, Utils {
_createUsers(3);

alice = users[0];
vm.label(alice.addr, "Alice");
bob = users[1];
vm.label(bob.addr, "Bob");
charlie = users[2];
vm.label(charlie.addr, "Charlie");
if (isZkSync) {
vm.label(alice.addr, "Alice");
vm.label(bob.addr, "Bob");
vm.label(charlie.addr, "Charlie");
}

resolvers = new address[](1);
resolvers[0] = bob.addr;
Expand All @@ -109,13 +111,16 @@ contract BaseSetup is Test, Utils {

function _deployTokens() internal {
dai = new TokenMock("DAI", "DAI");
vm.label(address(dai), "DAI");
usdc = new TokenCustomDecimalsMock("USDC", "USDC", 1000 ether, 6);
vm.label(address(usdc), "USDC");
inch = new TokenMock("1INCH", "1INCH");
vm.label(address(inch), "1INCH");
accessToken = new TokenMock("ACCESS", "ACCESS");
vm.label(address(accessToken), "ACCESS");

if (!isZkSync) {
vm.label(address(dai), "DAI");
vm.label(address(usdc), "USDC");
vm.label(address(inch), "1INCH");
vm.label(address(accessToken), "ACCESS");
}
}

function _deployContracts() internal {
Expand Down

0 comments on commit fcb7610

Please sign in to comment.