mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-23 06:33:42 +00:00
Organic Maps sources as of 02.04.2025 (fad26bbf22ac3da75e01e62aa01e5c8e11861005)
To expand with full Organic Maps and Maps.ME commits history run: git remote add om-historic [om-historic.git repo url] git fetch --tags om-historic git replace squashed-history historic-commits
This commit is contained in:
22
geometry/geometry_tests/rect_test.cpp
Normal file
22
geometry/geometry_tests/rect_test.cpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#include "testing/testing.hpp"
|
||||
#include "geometry/rect2d.hpp"
|
||||
|
||||
UNIT_TEST(Rect_Intersect)
|
||||
{
|
||||
m2::RectD r(0, 0, 100, 100);
|
||||
m2::RectD r1(10, 10, 20, 20);
|
||||
|
||||
TEST(r1.IsIntersect(r), ());
|
||||
TEST(r.IsIntersect(r1), ());
|
||||
|
||||
m2::RectD r2(-100, -100, -50, -50);
|
||||
|
||||
TEST(!r2.IsIntersect(r), ());
|
||||
TEST(!r.IsIntersect(r2), ());
|
||||
|
||||
m2::RectD r3(-10, -10, 10, 10);
|
||||
|
||||
TEST(r3.IsIntersect(r), ());
|
||||
TEST(r.IsIntersect(r3), ());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user