31435 - [SC - High] ALCX rewards arent claimed for from token when ...
Previous31430 - [SC - Insight] QANext31443 - [SC - Insight] Incorrect values of votingDelay and votingPerio...
Last updated
Was this helpful?
Was this helpful?
IRewardsDistributor(distributor).claim(_from, false);function testALCXRewardsNotClaimedOnMerge() public {
uint256 tokenId1 = createVeAlcx(admin, TOKEN_1, MAXTIME, false);
uint256 tokenId2 = createVeAlcx(admin, TOKEN_1, MAXTIME, false);
hevm.warp(minter.activePeriod() + nextEpoch);
voter.distribute();
assertGt(distributor.claimable(tokenId1), 0);
assertGt(distributor.claimable(tokenId2), 0);
hevm.prank(admin);
veALCX.merge(tokenId1, tokenId2);
assertGt(distributor.claimable(tokenId1), 0);
assertGt(distributor.claimable(tokenId2), 0);
vm.prank(admin);
vm.expectRevert(abi.encodePacked("not approved"));
distributor.claim(tokenId1, false);
}