[Bug] rbpf-tests attempt to run non-test generated interface move files #343
Comments
The regex allows subdirectories since commit 5fe4195, which adds tests that are contained in subdirectiories. The easiest solution at the moment is probably just to create a more complicated regex that rejects paths containing something like |
Why don't we have a clean-up before running so each run will be like the first run? |
The primary difficulty is that the |
I'm finding that it is actually hard to write a regex that says "allow all strings except one's that contain '-build/'". This isn't something the Rust regex engine can do in an obvious way. |
We can possibly have the tests that link to the stdlib clean up after themselves to delete the |
ok I have a regex that works. I'll post it shortly. |
Maybe regex is good for now, but if the starting positions for different runs are not the same it will always remain a legit source of suspicion. |
Good point. It looks like each individual test does clean up their build directories prior to doing their individual builds, so the tests shouldn't be building into dirty build directories; but there is no single step to clean up all build directories at once. |
For CI checks this shouldn't matter, because they always run in a new clone of the repository. |
For CI indeed, but before CI we do a local test run and it may come out misleadingly correct. |
After running rbpf-tests once, a second run will fail with errors like:
This is because of an interaction between the test_harness macro and tests that compile the stdlib: compiling the standard library generates "interface files" that have a
.move
extension, and they are generated under subdirectories of therbpf-tests
directory.The test_harness regex looks like:
This regex allows tests to be located in subdirs, so it pickes up the generated files and fails them.
The text was updated successfully, but these errors were encountered: