Bugfix: Fix blockchain tests: It was quietly skipping 4654 of them

The "new block chain json tests" were being skipped on Linux, but silently so
that CI didn't notice.  These are a significant part of the Ethereum test suite.

See the missing output from `make test`, also visible in CI logs for Linux
targets (prior to this commit):

      [OK] tests/fixtures/eth_tests/TransactionTests/ttGasPrice/TransactionWithGasPriceOverflow.json
      [OK] tests/fixtures/eth_tests/TransactionTests/ttGasPrice/TransactionWithHighGasPrice.json

    [Suite] new block chain json tests
            <-- nothing here

    [Suite] Fork ID tests
      [OK] MainNet
      [OK] RopstenNet

Commit 3d468a7 (`fixes path pointing to eth_tests`) renamed the JSON fixture
source directoryf in the witness-builder tests but not the regular blockchain
tests.  As a result, searching for JSON test files yielded zero results.  To
make this less likely in future, zero results is now an error.

Signed-off-by: Jamie Lokier <jamie@shareable.org>
This commit is contained in:
Jamie Lokier 2021-04-08 10:29:25 +01:00
parent e4bd5532c5
commit 8a806da600
No known key found for this signature in database
GPG Key ID: CBC25C68435C30A2
2 changed files with 3 additions and 1 deletions

View File

@ -760,7 +760,7 @@ proc testFixture(node: JsonNode, testStatusIMPL: var TestStatus, debugMode = fal
proc blockchainJsonMain*(debugMode = false) =
const
legacyFolder = "eth_tests" / "LegacyTests" / "Constantinople" / "BlockchainTests"
newFolder = "eth_tests" / "BlockChainTests"
newFolder = "eth_tests" / "BlockchainTests"
let config = test_config.getConfiguration()
if config.testSubject == "" or not debugMode:

View File

@ -91,6 +91,8 @@ proc jsonTestImpl*(inputFolder, outputName: string, handler, skipTest: NimNode):
if `skipTest`(last, name):
continue
filenames.add(filename)
doAssert(filenames.len > 0)
for fname in filenames:
test fname:
{.gcsafe.}: