dijkstra is now bleching fast

deleting from the grid is now bleaching fast
added new helper methods
many new test-cases
many new methods for geo classes and others
added a bunch of new grid-walkers
This commit is contained in:
2016-01-26 18:13:30 +01:00
parent b503fb9bdc
commit e6329e1db4
26 changed files with 824 additions and 179 deletions

24
tests/geo/TestPoint.cpp Normal file
View File

@@ -0,0 +1,24 @@
#ifdef WITH_TESTS
#include "../Tests.h"
#include "../../geo/Point3.h"
TEST(Point3, math) {
Point3 p1(1,2,3);
p1 += Point3(2,3,4);
ASSERT_EQ(p1, Point3(3,5,7));
Point3 p2 = Point3(-2,-1,-4) + p1;
ASSERT_EQ(p2, Point3(1, 4, 3));
p2 -= Point3(1, 2, 3);
ASSERT_EQ(p2, Point3(0,2,0));
Point3 p3 = Point3(1,2,3)*2;
ASSERT_EQ(p3, Point3(2,4,6));
}
#endif

View File

@@ -140,7 +140,7 @@ public:
Plot& fire() {
gp.draw(splot);
gp.flush();
sleep(1000);
//sleep(1000);
return *this;
}

View File

@@ -12,7 +12,7 @@
#include "../../grid/walk/GridWalkWeighted.h"
#include "../../grid/walk/GridWalkLightAtTheEndOfTheTunnel.h"
TEST(Walk, plot) {
TEST(Walk, DISABLED_plot) {
Grid<GP> g(20);
GridFactory<GP> gf(g);