| 8 | #include "fields2cover/types.h" |
| 9 | |
| 10 | TEST(fields2cover_types_swath, hasSameDir) { |
| 11 | F2CSwath swath1(F2CLineString({F2CPoint(0, 0), F2CPoint(1, 1)}), 1.0); |
| 12 | F2CSwath swath2 = swath1.clone(); |
| 13 | swath2.reverse(); |
| 14 | EXPECT_TRUE(swath1.hasSameDir(swath1)); |
| 15 | EXPECT_FALSE(swath1.hasSameDir(swath2)); |
| 16 | EXPECT_FALSE(swath2.hasSameDir(swath1)); |
| 17 | swath1.targetSameDirAs(swath2); |
| 18 | EXPECT_TRUE(swath1.hasSameDir(swath2)); |
| 19 | EXPECT_EQ(swath1.getPoint(0), F2CPoint(1, 1)); |
| 20 | } |
| 21 | |
| 22 | TEST(fields2cover_types_swath, comparison) { |
| 23 | F2CSwath swath1(F2CLineString({F2CPoint(0, 0), F2CPoint(1, 1)}), 1.0, 1); |
nothing calls this directly
no test coverage detected