From d2eb84d8423b58f97559a1c90cdc3178661e2f33 Mon Sep 17 00:00:00 2001 From: Keating Date: Wed, 14 Feb 2024 15:09:26 -0500 Subject: [PATCH] More changes --- test/WormholeL1VotePool.t.sol | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/WormholeL1VotePool.t.sol b/test/WormholeL1VotePool.t.sol index 36c0dfa7..8f81f961 100644 --- a/test/WormholeL1VotePool.t.sol +++ b/test/WormholeL1VotePool.t.sol @@ -22,6 +22,7 @@ contract WormholeL1VotePoolTest is TestConstants, WormholeRelayerBasicTest { FakeERC20 l2Erc20; FakeERC20 l1Erc20; GovernorFlexibleVotingMock gov; + uint128 DEFAULT_VOTE_END; event VoteCast( address indexed voter, @@ -49,6 +50,7 @@ contract WormholeL1VotePoolTest is TestConstants, WormholeRelayerBasicTest { L1_CHAIN.wormholeChainId, 1200 ); + DEFAULT_VOTE_END = uint128(l2VoteAggregator.CAST_VOTE_WINDOW()) + 1; } function setUpTarget() public override { @@ -97,7 +99,7 @@ contract _ReceiveCastVoteWormholeMessages is WormholeL1VotePoolTest { vm.deal(address(this), 10 ether); l2VoteAggregator.createProposalVote(_proposalId, _l2Against, _l2For, _l2Abstain); - l2VoteAggregator.createProposal(_proposalId, uint128(l2VoteAggregator.CAST_VOTE_WINDOW()) + 1); + l2VoteAggregator.createProposal(_proposalId, DEFAULT_VOTE_END); vm.expectEmit(); emit VoteBridged(_proposalId, _l2Against, _l2For, _l2Abstain); l2VoteAggregator.bridgeVote{value: cost}(_proposalId); @@ -151,7 +153,7 @@ contract _ReceiveCastVoteWormholeMessages is WormholeL1VotePoolTest { vm.deal(address(this), 10 ether); l2VoteAggregator.createProposalVote(_proposalId, _l2NewAgainst, _l2NewFor, _l2NewAbstain); - l2VoteAggregator.createProposal(_proposalId, uint128(l2VoteAggregator.CAST_VOTE_WINDOW()) + 1); + l2VoteAggregator.createProposal(_proposalId, DEFAULT_VOTE_END); vm.expectEmit(); emit VoteBridged(_proposalId, _l2NewAgainst, _l2NewFor, _l2NewAbstain); l2VoteAggregator.bridgeVote{value: cost}(_proposalId);