-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
partial hash check for mock_sentry.go (#11964)
> I encountered a problem in the way we run execution-spec-tests, and need more eyes on it: some execution spec tests have a failure associated with a block. An example is: a 7702 tx with empty auth list should cause block rejection because such a tx is invalid. now when the BlockTest#Run executes, it tries to "insertChain", after which mock_sentry does block.HashCheck() before calling the el to insert block. one of the check in HashCheck() is that if receiptRoot is emptyRootHash and block has any tx, it rejects the block right there, even before sending it to el (lots if not all execution-spec-tests wherein block should be rejected have receiptRoot=emptyRootHash) The execution-spec-test in the above scenario passes, since the block was "rejected". But this can (and does) lead to false positive test-success, as the block is never executed, so we don't actually check if the block is rejected "for correct reasons". So for example, recently Mario added a test to check "tx should not be nil in 7702 tx" in latest spec tests. This is not done by our code, but the test still passes because the rejection happens at block.HashCheck() to counter these false positives, I add a `fullCheck` flag for `HashCheck` which bypasses the empty receipt check for mock_sentry.
- Loading branch information
1 parent
a5dd9d8
commit 372e62c
Showing
5 changed files
with
13 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters