Feat: move two-step shell script into test_runner.py#891
Feat: move two-step shell script into test_runner.py#891jaoleal wants to merge 2 commits intogetfloresta:masterfrom
test_runner.py#891Conversation
test_runner.py
0e67a53 to
9e77d00
Compare
|
I also included a option to expose the general TIMEOUT, with that, people that have constrained environments to run the tests can have better control over the tests runtime. For example, on my laptop i needed to use: |
9e77d00 to
bf984e0
Compare
|
Okay guys, i changed UTREEXOD_REVISION to 878794f30cf0ffd499bc03551186ce6a5c16b67e it appears to be the correct commit to update the service flags problem. |
moisesPompilio
left a comment
There was a problem hiding this comment.
Rather than having test_runner call setup, setup should be the entry point and trigger the process. We're migrating to pytest, so test_runner will be removed. It's better for this Python script to behave like the .sh we used and be decoupled from the code.
tests/test_framework/setup.py
Outdated
| return temp_dir | ||
|
|
||
| git_desc = _git_describe() | ||
| temp_dir = f"/tmp/floresta-func-tests.{git_desc}" |
There was a problem hiding this comment.
Only the log folder includes git_describe; the other folders don't. This prevents re-downloading the commit each time a test session creates a commit.
bf984e0 to
687e610
Compare
The two-step workflow (prepare.sh then run.sh) required callers to run scripts in sequence and share FLORESTA_TEMP_DIR between them. Merge both into a single run_functional.sh that builds all binaries, runs the test suite, and cleans up — in one invocation. Also pins utreexod to v0.4.0 by default via UTREEXOD_REVISION and updates the justfile, CI workflow, and docs accordingly.
8c150b3 to
af5ff29
Compare
okay, after some changes, |
Replace the shell-based test setup (run_functional.sh) with a Python module (tests/test_framework/setup.py) that implements the same approach: build or download utreexod and bitcoind, and always build florestad, before running the test suite. The test runner (tests/test_runner.py) becomes the single entry point, keeping the flags: --force-rebuild, --release, and --preserve-data-dir. Also updates doc/running-tests.md accordingly.
af5ff29 to
0a9b5ce
Compare
Description and Notes
Replace integration test shell script with
tests/test_framework/setup.pyfor binary preparation and directory schema orchestration.test_runner.pyis now the single entry point — handles building/downloading binaries and running the suite.--force-rebuild,--release, and--preserve-data-dirflags.data/andlogs/directories before each run so failed runs don't lead any run into a corrupted state.doc/running-tests.mdaccordingly.Why ? : I expect for this changes to provide more quality of use while running locally the tests by solving edge cases that break the test environment and by gathering the steps to run the tests into a single one,
uv run ./test/test_runner.py.How to verify the changes you have done?
I tried to make a logical flow of the changes that got from having two shell scripts to extend the test runner with the same functionality. The first commit merge both
./test/prepare.shand./test/run.shintorun_funtcional.sh, the second one is the one rewriting it into thetest_runner.py.