-
Notifications
You must be signed in to change notification settings - Fork 164
Add interface IDs directly to Typechain generated factories #1240
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
7219ea2
6115ac9
3a1c02f
03a63fd
2185f88
b3913da
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,18 +1,18 @@ | ||
| // SPDX-License-Identifier: MIT | ||
| pragma solidity 0.8.27; | ||
|
|
||
| import "forge-std/Test.sol"; | ||
|
Check warning on line 4 in packages/horizon/test/unit/staking/slash/slash.t.sol
|
||
|
|
||
| import { IHorizonStakingMain } from "@graphprotocol/interfaces/contracts/horizon/internal/IHorizonStakingMain.sol"; | ||
|
Check warning on line 6 in packages/horizon/test/unit/staking/slash/slash.t.sol
|
||
|
|
||
| import { HorizonStakingTest } from "../HorizonStaking.t.sol"; | ||
|
|
||
| contract HorizonStakingSlashTest is HorizonStakingTest { | ||
|
Check warning on line 10 in packages/horizon/test/unit/staking/slash/slash.t.sol
|
||
| /* | ||
| * TESTS | ||
| */ | ||
|
|
||
| function testSlash_Tokens( | ||
|
Check warning on line 15 in packages/horizon/test/unit/staking/slash/slash.t.sol
|
||
| uint256 tokens, | ||
| uint32 maxVerifierCut, | ||
| uint256 slashTokens, | ||
|
|
@@ -20,7 +20,7 @@ | |
| ) public useIndexer useProvision(tokens, maxVerifierCut, 0) { | ||
| slashTokens = bound(slashTokens, 1, tokens); | ||
| uint256 maxVerifierTokens = (slashTokens * maxVerifierCut) / MAX_PPM; | ||
| vm.assume(verifierCutAmount <= maxVerifierTokens); | ||
|
|
||
| vm.startPrank(subgraphDataServiceAddress); | ||
| _slash(users.indexer, subgraphDataServiceAddress, slashTokens, verifierCutAmount); | ||
|
|
@@ -172,6 +172,10 @@ | |
| vm.assume(delegationTokensToSlash <= delegationTokens); | ||
| vm.assume(delegationTokensToUndelegate <= delegationTokens); | ||
| vm.assume(delegationTokensToUndelegate > 0); | ||
| vm.assume( | ||
| delegationTokensToUndelegate == delegationTokens || | ||
| MIN_DELEGATION <= delegationTokens - delegationTokensToUndelegate | ||
| ); | ||
|
|
||
| resetPrank(users.delegator); | ||
| _delegate(users.indexer, subgraphDataServiceAddress, delegationTokens, 0); | ||
|
|
||
This file was deleted.
Uh oh!
There was an error while loading. Please reload this page.