results: fix Debug rendering assertion #18

Merged
mcp merged 2 commits from codex/issue-7-results-assert into main 2026-07-30 16:47:26 +01:00
Collaborator

Summary

  • add a valid order-8 rendering regression test
  • fix Results::set() to inspect the output buffer instead of nonexistent grid_
  • retain the intended same-character duplicate-write assertion
  • update Debug testing guidance

Commit structure

  1. test: cover rendering a valid solution — Release passes; Debug compilation fails on the bad grid_ reference
  2. results: fix Debug rendering assertion — Debug and Release pass

Testing

  • Debug CTest: 4/4 passed
  • Release CTest: 4/4 passed
  • git diff --check: passed

Review

Independent review found no functional issues. Two documentation inaccuracies were corrected before push: labels overwrite interior spaces, not border characters, and Debug no longer exposes #7.

Closes #7
Part of #16

## Summary - add a valid order-8 rendering regression test - fix `Results::set()` to inspect the output buffer instead of nonexistent `grid_` - retain the intended same-character duplicate-write assertion - update Debug testing guidance ## Commit structure 1. `test: cover rendering a valid solution` — Release passes; Debug compilation fails on the bad `grid_` reference 2. `results: fix Debug rendering assertion` — Debug and Release pass ## Testing - Debug CTest: 4/4 passed - Release CTest: 4/4 passed - `git diff --check`: passed ## Review Independent review found no functional issues. Two documentation inaccuracies were corrected before push: labels overwrite interior spaces, not border characters, and Debug no longer exposes #7. Closes #7 Part of #16
mcp added 2 commits 2026-07-30 16:47:18 +01:00
Exercise Results::output() with the known order-8 fixture so Debug builds compile and run the rendering assertions. Check the output dimensions and ensure the valid tiling leaves no unrendered cells.

The test passes in Release and currently fails to compile in Debug because Results::set() refers to the nonexistent grid_ member.

Refs: #7
Check the character in the output string instead of referring to a nonexistent grid_ member. This restores Debug compilation while preserving the intended invariant that rendering must not write an identical character twice.

Size labels intentionally replace interior spaces, so requiring an entirely unwritten destination would reject valid solutions. Update the testing notes now that Debug builds pass.

Tests: Debug and Release CTest suites (4 passed each)

Refs: #7
mcp merged commit ebfc80546a into main 2026-07-30 16:47:26 +01:00
mcp deleted branch codex/issue-7-results-assert 2026-07-30 16:47:26 +01:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mgrettondann/partridge-cpp#18