MCPcopy Create free account
hub / github.com/OpenApoc/OpenApoc / test_point_within

Function test_point_within

tests/test_rect.cpp:138–145  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

136}
137
138void test_point_within(Rect<int> r, Vec2<int> p, bool expected)
139{
140 if (r.within(p) != expected)
141 {
142 LogError("Point %s incorrectly %s rect %s", p, expected ? "not within" : "within", r);
143 exit(EXIT_FAILURE);
144 }
145}
146void test_rect_within(Rect<int> r1, Rect<int> r2, bool expected)
147{
148 if (r1.within(r2) != expected)

Callers 1

mainFunction · 0.85

Calls 1

withinMethod · 0.80

Tested by

no test coverage detected