-
Notifications
You must be signed in to change notification settings - Fork 21
FIX: --no-gen-tests Flag Causes Path Resolution Error with Module-Root #1086
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…oss-platform compatibility. Remove redundant path matching logic and enhance logging in parse_test_xml for better debugging of test type registration issues.
| test_file | ||
| for test_file in self.test_files | ||
| if test_file.original_file_path is not None | ||
| and normalized == self._normalize_path_for_comparison(test_file.original_file_path) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can refactor self._normalize_path_for_comparison(test_file.original_file_path) out for better readability
| if normalized == self._normalize_path_for_comparison(test_file.instrumented_behavior_file_path) | ||
| or ( | ||
| test_file.benchmarking_file_path is not None | ||
| and normalized == self._normalize_path_for_comparison(test_file.benchmarking_file_path) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same feedback as previous comment
⚡️ Codeflash found optimizations for this PR📄 702% (7.02x) speedup for
|
⚡️ Codeflash found optimizations for this PR📄 73% (0.73x) speedup for
|
Fix: Handle missing test file registration gracefully with improved path matching
Path normalization: Added a helper that normalizes paths before comparison:
Error handling: Replaced the assertion with a warning that:
Changes
models.py: Added_normalize_path_for_comparison()and updated path comparison methods to use itparse_test_output.py: Replaced assertion with warning and continueImpact
Fixes the crash and improves robustness when test file paths don't match exactly.