add tests

This commit is contained in:
Atsushi Sakai
2018-01-13 10:07:54 -08:00
parent ebeb3d955b
commit bdebdb8784
2 changed files with 21 additions and 5 deletions

View File

@@ -300,11 +300,12 @@ def main():
path = rrt.Planning(animation=show_animation)
# Draw final path
rrt.DrawGraph()
plt.plot([x for (x, y) in path], [y for (x, y) in path], '-r')
plt.grid(True)
plt.pause(0.001)
plt.show()
if show_animation:
rrt.DrawGraph()
plt.plot([x for (x, y) in path], [y for (x, y) in path], '-r')
plt.grid(True)
plt.pause(0.001)
plt.show()
if __name__ == '__main__':