test: improve performance of language scanner tests #5011
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.
Performance Improvements for Language Scanner Tests
This PR addresses issue #4321 by significantly improving the performance of our slowest tests in the test suite.
Changes
1. Reduced Product Lists
2. Minimized Test Files
Cargo.lock
: Reduced from 2725 lines to ~50 linesGemfile.lock
: Reduced from 634 lines to ~25 linesrenv.lock
: Reduced from 1677 lines to ~30 linesrequirements.txt
: Reduced from 20 lines to 3 linesgo.mod
: Reduced to include only 3 productspackage-lock.json
: Reduced to include only 2 products3. Optimized Test Function
test_language_package
to:Expected Performance Improvement
Based on the original measurements, we should see significant improvements:
Cargo.lock
test: from 291s to potentially under 10sGemfile.lock
test: from 203s to potentially under 10srequirements.txt
test: from 119s to potentially under 5srenv.lock
test: from 99s to potentially under 5sThese changes maintain test coverage while dramatically reducing execution time.
Fixes #4321