Example #1
0
 def test_draw_white2(self):
     s = Smoother([[0]])
     pb = PathBuilder()
     s._draw_white(pb, 0, 0, NW | NE | SE | SW)
     pb.optimize()
     self.assertEqual(pb.generate_paths(),
                      [[(0, 0), (10, 0), (10, 10),
                        (0, 10)], [(2, 5), (5, 8), (8, 5), (5, 2)]])
Example #2
0
 def test_draw_white(self):
     s = Smoother([[0]])
     pb = PathBuilder()
     s._draw_white(pb, 20, 30, NW)
     pb.optimize()
     self.assertEqual(pb.generate_paths(), [[(20, 30), (27, 30), (20, 37)]])