test: tighten waveform-collapse and knob-face rect assertions
Height-3 case pins the halfSpan clamp itself (height-4 passed pre-fix too); dropped the vacuous tall-rect mirror since min() is symmetric and wide already discriminates.
This commit is contained in:
@@ -395,12 +395,8 @@ static void testInKnobFaceUsesTheSmallerDimensionOnANonSquareRect() {
|
||||
CHECK(!inKnobFace(wide, cx, cy + 15)); // inside the RECT but outside the smaller-radius disc
|
||||
CHECK(!inKnobFace(wide, cx + 15, cy)); // same check along the wider axis
|
||||
|
||||
const Rect tall{0, 0, 20, 40}; // height > width: draws a 10px-radius disc, not 20px
|
||||
const int tcx = tall.x + tall.width / 2;
|
||||
const int tcy = tall.y + tall.height / 2;
|
||||
CHECK(inKnobFace(tall, tcx, tcy));
|
||||
CHECK(!inKnobFace(tall, tcx + 15, tcy));
|
||||
CHECK(!inKnobFace(tall, tcx, tcy + 15));
|
||||
// No mirrored tall{20,40} case: min() is symmetric in its two arguments, so a tall rect
|
||||
// can't discriminate width/2 from min(w,h)/2 any differently than wide already does.
|
||||
}
|
||||
|
||||
static void testEmptyDeck() {
|
||||
|
||||
Reference in New Issue
Block a user