-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Expand forge test --match
interface
#388
Conversation
…tract name, and their inverse
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
really great work - clean.
Thanks @gakonst, appreciate it |
I'm in the process of migrating a larger dapptools project to foundry. We have separate contracts for rpc based tests and local tests grouped by directory. The only way to do this with forge atm would be to have an external script which generates a custom regex string and supply that to To streamline this I would either extend |
@lattejed see above, nice idea |
I'll take a look at it |
From issue: #227
This PR deprecates
forge test --match
and expands the match interface to--match-test
--no-match-test
--match-contract
--no-match-contract
to allow for more granular test matching.
Internally, test runners have
Regex
replaced withtrait/impl TestFilter
to allow for custom matching logic in client code.Conflicts have been added between
--match
and the new options to prevent mix/match of these. However,--match
is effectively aliased to--match-test
so there are no breaking changes.Affected tests have been updated.
Any / all input welcome.