Each line of the file is one test case that comes with a graph definition and 10 tests:
- Calculate distance along a valid route
- Calculate distance along a valid route
- Calculate distance along a valid route
- Calculate distance along a valid route
- Throw error if calculate distance with an invalid route
- Number of routes between 2 nodes with a maximum stops limitation
- Number of routes between 2 nodes with exact stops limitation
- Calculate shortest distance between 2 nodes
- Calculate shortest distance between 2 nodes
- Calculate routes between 2 nodes with a maximum distance limitation
Run go run main.go "test.data" (assumed that test.data is the test file) in the root directory of the repo
Run go test -v ./... (argument -v is optional) in the root directory of the repo
Michael Bui from GigaryTeam