]> rtime.felk.cvut.cz Git - hubacji1/psp.git/commitdiff
Add ut for fe method
authorJiri Vlasak <hubacji1@fel.cvut.cz>
Tue, 23 Jul 2019 11:50:37 +0000 (13:50 +0200)
committerJiri Vlasak <hubacji1@fel.cvut.cz>
Tue, 23 Jul 2019 11:50:37 +0000 (13:50 +0200)
ut/psp.t.cc

index d1ea09467ce2c08e8fa5c75a9da2c1a70718c08a..47adc30ee273bbff62f6bc861942ac19d9c4c8df 100644 (file)
@@ -29,6 +29,12 @@ WVTEST_MAIN("parallel parking slot planner")
         psp.fer();
         WVPASS(psp.left());
 
+        // find entry
+        psp.cc() = BicycleCar(psp.gc());
+        WVPASS(!psp.left());
+        psp.fe();
+        WVPASS(psp.left());
+
         // collide
         auto tmpi1 = intersect(1, 1, 3, 3, 1, 3, 3, 1);
         WVPASS(std::get<0>(tmpi1));
@@ -71,6 +77,12 @@ WVTEST_MAIN("backward perpendicullar parking slot planner")
         WVPASS(!psp.left());
         psp.fer();
         WVPASS(psp.left());
+
+        // find entry
+        psp.cc() = BicycleCar(psp.gc());
+        WVPASS(!psp.left());
+        psp.fe();
+        WVPASS(psp.left());
 }
 
 WVTEST_MAIN("forward perpendicullar parking slot planner")
@@ -98,4 +110,10 @@ WVTEST_MAIN("forward perpendicullar parking slot planner")
         WVPASS(!psp.left());
         psp.fer();
         WVPASS(psp.left());
+
+        // find entry
+        psp.cc() = BicycleCar(psp.gc());
+        WVPASS(!psp.left());
+        psp.fe();
+        WVPASS(psp.left());
 }