• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Alan-Jowett / bdd_test / 19214734872

09 Nov 2025 09:30PM UTC coverage: 86.172% (-2.5%) from 88.636%
19214734872

push

github

web-flow
feat: Replace flaky expression parser with robust recursive descent implementation (#23)

* feat: Replace flaky expression parser with robust recursive descent implementation

BREAKING CHANGE: Complete rewrite of expression parser with comprehensive improvements

## Major Changes

### ๐Ÿ”„ Parser Implementation
- Replace unreliable regex-based parser with robust recursive descent parser
- Implement proper operator precedence (NOT > AND > OR > XOR)
- Add comprehensive tokenizer with boundary detection for operator keywords
- Support variables containing operator names (e.g., 'foo_AND_bar')
- Fix std::isspace safety with unsigned char casting for Unicode support

### ๐Ÿงช Testing & Quality
- Add 5 comprehensive regression tests covering critical edge cases:
  * boundary_detection_regression: Variable tokenization validation
  * complex_boundary_regression: Complex variable naming scenarios
  * operator_keywords_in_vars: Operator keyword positioning tests
  * unicode_chars_regression: Extended ASCII character safety
  * error_message_regression: Human-readable error message validation
- Update CMake test infrastructure to handle subdirectory test organization
- All 29 tests passing (100% success rate)

### ๏ฟฝ๏ฟฝ Documentation & Code Quality
- Add complete Doxygen documentation for all functions in expression_parser.cpp
- Move implementation details into anonymous namespaces for better encapsulation
- Apply clang-format for consistent code style throughout
- Fix CI workflow to handle generated test output files properly

### ๐Ÿ›  Tooling & Infrastructure
- Add generate_regression_pngs.ps1 script for PNG visualization generation
- Include reference files for all regression test comparisons
- Support both BDD graph and expression tree visualizations
- Ensure CI/CD pipeline compatibility with new test structure

## Key Benefits
- โœ… Robust parsing with proper error handling and boundary detection
- โœ… Comprehensive test coverage preventing future regressions
- โœ… Professio... (continued)

691 of 844 branches covered (81.87%)

Branch coverage included in aggregate %.

130 of 151 new or added lines in 1 file covered. (86.09%)

3 existing lines in 1 file now uncovered.

680 of 747 relevant lines covered (91.03%)

224.77 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

80.96
/src/expression_parser.cpp


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc