-
-
Notifications
You must be signed in to change notification settings - Fork 378
Automated Testing (Unit Tests)
justjkk edited this page May 5, 2011
·
4 revisions
To provide unit tests for the core functions(c++) and also to the wrapper functions(sql) to make it easier to check for bugs before committing changes.
- CUnit provides a framework for running tests against c/c++ code
- It is used by PostGIS to test its geometry library(liblwgeom)
- It is used to test core functions implementing routing algorithms and has the advantage that future integration with PostGIS will be a bit easier
- Link to project page
- `unittest` is an easy to use python testing framework
- It is used to test pl/pgsql functions using psycopg2 driver for PostgreSQL
- Link to unittest library
- CTest is provided by CMake, the build system used by pgrouting
- Ties down the testing code into CMake configuration
- CTest is used to invoke the above two frameworks to test the c/c++ code as well as the core and wrapper SQL functions
- Link to CTest wikipage
The code is under active development in a separate branch: https://github.com/justjkk/pgrouting/commits/unittests
- Tests are written for validating boost wrapper of dijkstra implementation
- Have to write tests for other routing algorithm implementations like Astar, Shooting star, etc...
- The basic framework for creating test database, loading just compiled SQL functions, creating and populating test tables are done
- Very primitive testing for Dijkstra(proof of concept) is implemented
- Have to write tests for all core and wrapper SQL functions with diverse test data