feat: Enhanced testsuite framework with improved error reporting and debugging capabilities#3716
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Copilot
AI
changed the title
[WIP] proposal: Testsuite Framework Improvements
feat: Enhanced testsuite framework with improved error reporting and debugging capabilities
Sep 23, 2025
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.OpenSSF Scorecard
Scanned Files
|
Co-authored-by: jolestar <77268+jolestar@users.noreply.github.com>
…nced features Co-authored-by: jolestar <77268+jolestar@users.noreply.github.com>
Co-authored-by: jolestar <77268+jolestar@users.noreply.github.com>
d117242 to
3e0ffdf
Compare
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.
This PR significantly enhances the integration test framework in
crates/testsuite/tests/integration.rsto provide better error reporting, debugging capabilities, and user experience for developers working with Rooch integration tests.Problem
The current integration test framework has several critical issues that make debugging test failures extremely difficult:
Example of the previous confusing error output:
Solution
This implementation adds comprehensive debugging infrastructure with:
1. Enhanced Error Reporting System
TestExecutionContextandCommandExecutionstructures to track test state2. Template Debugging Capabilities
TemplateContextExttrait provides step-by-step template resolution debugging3. Configurable Logging Levels
ROOCH_TEST_LOG_LEVEL: Control output verbosity (minimal|normal|verbose|debug)ROOCH_TEST_TEMPLATE_DEBUG: Enable detailed template debuggingROOCH_TEST_SHOW_PROGRESS: Progressive test execution indicatorsROOCH_TEST_TIMEOUT: Configurable command timeouts4. Progressive Test Execution Display
5. Enhanced Assertion Messages
Usage
Development mode with progress indicators:
ROOCH_TEST_LOG_LEVEL=verbose ROOCH_TEST_SHOW_PROGRESS=true cargo test --test integration -- --nocaptureFull debugging mode:
ROOCH_TEST_LOG_LEVEL=debug ROOCH_TEST_TEMPLATE_DEBUG=true ROOCH_TEST_SHOW_PROGRESS=true cargo test --test integration -- --nocaptureCI/minimal mode:
ROOCH_TEST_LOG_LEVEL=minimal cargo test --test integrationFiles Added/Modified
crates/testsuite/tests/integration.rs- Core framework enhancementscrates/testsuite/Cargo.toml- Added regex dependency for template parsingcrates/testsuite/DEBUGGING.md- Comprehensive debugging guidecrates/testsuite/features/README.md- Updated documentationcrates/testsuite/demo.sh- Interactive demonstration scriptBackward Compatibility
All existing
.featurefiles continue to work without any changes. The enhancements are completely opt-in through environment variables.Benefits
Fixes #3715.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
esm.ubuntu.com/usr/lib/apt/methods/https(dns block)If you need me to access, download, or install something from one of these locations, you can either:
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.