You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(waiter): add doctests for utility pattern matching functions
# What was changed
- Added doctests for _contains_match showing patterns found, not found, and spanning multiple lines
- Added doctests for _regex_match demonstrating string patterns, compiled patterns, and regex groups
- Added doctests for _match_regex_across_lines showing multi-line pattern matching
- Fixed implementation in _match_regex_across_lines to correctly determine starting line of multi-line matches
- Fixed doctest in _contains_match to properly handle raw string escaping
# Why these changes were made
- Documentation as code: Provides executable examples of these utility functions
- Quality assurance: Verifies that functions behave as expected
- Previous line detection couldn't correctly identify which line a multi-line match started on
- The new position-based approach correctly calculates starting line by counting newlines
- The doctest fixes ensure correct testing of multi-line pattern matching
0 commit comments