test: Collect the test files in one place - #1680
Open
chfast wants to merge 1 commit into
Open
Conversation
Both drivers walked the directory themselves, with the same recursive search, the same index.json skip, the same sort and the same suite naming written out twice. Only the registration at the end differed. collect_test_files() in testutils does the walk once and returns each file with the suite it belongs to. The listed tests are unchanged, name for name: 20245 for the state tool and 21333 for the blockchain one, in the same order.
Contributor
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1680 +/- ##
==========================================
+ Coverage 97.86% 97.89% +0.02%
==========================================
Files 176 178 +2
Lines 15995 16026 +31
Branches 3666 3671 +5
==========================================
+ Hits 15654 15689 +35
Misses 255 255
+ Partials 86 82 -4
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
evmone-statetestandevmone-blockchaintesteach walked the test directory themselves, and thetwo walks were the same code: the recursive search, the
.jsonfilter, theindex.jsonskip, thesort, and the suite name taken from the file's directory relative to the root. Only the
registration call at the end differed.
collect_test_files()in testutils does it once andreturns each file with the suite it belongs to, which also gives the flags planned next
(
--ignore,--collect-only) a single list to work from.Nothing about the registered tests changes.
--gtest_list_testsover the EEST fixtures isbyte-identical to master — 20245 names for the state tool, 21333 for the blockchain one, in the
same order — which is what the CI filters and the integration tests' expected output depend on.
The walk was previously unreachable from a unit test; four tests now pin the suite naming, the
index.jsonskip and the ordering.