k-wave-python icon indicating copy to clipboard operation
k-wave-python copied to clipboard

Add edge case tests for refactored make_line functions

Open Copilot opened this issue 3 months ago • 1 comments

Adds comprehensive edge case tests for make_line_straight and make_line_angled functions introduced in the refactoring.

Test Coverage

make_line_straight (8 tests):

  • Boundary slopes: horizontal (m=0), vertical (m=∞), diagonal (m=±1)
  • Extreme slopes: steep (|m|>1), shallow (|m|<1)
  • Grid boundaries and short 2-point lines

make_line_angled (11 tests):

  • Cardinal angles: 0, π/2, -π/2, π
  • All quadrants: π/4, 3π/4, -π/4, -3π/4
  • Edge cases: zero length, boundary exceeding, angle wrapping (>2π)
  • Grid size variations

All 19 tests validate current behavior including 1-indexed coordinates and grid boundary handling.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot avatar Nov 12 '25 14:11 Copilot