Skip to content

Conversation

@gitauto-ai
Copy link
Contributor

@gitauto-ai gitauto-ai bot commented Dec 2, 2025

Resolves #1998

Summary

Add comprehensive unit tests for utils/logs/remove_pytest_sections.py targeting full coverage and explicitly exercising the previously uncovered branch around line 32.

Test Patterns

  • Removes pytest sections when present while preserving surrounding non-pytest content (happy path).
  • No pytest markers present: returns input unchanged (covers branch at ~line 32).
  • Partial/malformed sections (only start or only end marker): handled gracefully without exceptions; behavior matches current implementation.
  • Multiple pytest sections within one log: all sections removed.
  • Overlapping/nested-like markers: boundaries respected; only intended ranges removed.
  • Empty and whitespace-only inputs.
  • Large input (stress) to ensure performance and no pathological behavior.
  • Mixed newline styles (LF/CRLF) and mixed endings preserved appropriately.
  • Logs containing ANSI color codes and Unicode characters: only pytest sections removed; other content intact.
  • Invalid input types (e.g., None, bytes): raises the expected exception.
git fetch origin
git checkout gitauto/issue-1998-20251202-000525-iz2i
git pull origin gitauto/issue-1998-20251202-000525-iz2i

@gitauto-ai gitauto-ai bot requested a review from hiroshinishio as a code owner December 2, 2025 00:06
@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

@gitauto-ai
Copy link
Contributor Author

gitauto-ai bot commented Dec 2, 2025

Finished fixing the build check run error!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Schedule: Add unit tests to utils/logs/remove_pytest_sections.py

2 participants