ps2.test
Class WalkingRouteFormatterTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by ps2.test.WalkingRouteFormatterTest
All Implemented Interfaces:
Test

public class WalkingRouteFormatterTest
extends TestCase

Unit tests for the WalkingRouteFormatter class.


Constructor Summary
WalkingRouteFormatterTest()
           
 
Method Summary
protected  void setUp()
           
 void testDistance()
          Test rounding distance, specifically if it rounds up to 0.1 and rounds down to 0.0.
 void testLongRoute()
          Long route with no repeats.
 void testRepeatedRoute()
          Just like long route, but different makeup of geosegements.
 void testRepeatedSegment()
          Two step route with one geo feature.
 void testShortDirections()
          Test simple directions with one distance and one origHeading.
 void testTurning()
          Test turning directions, with different origHeadings.
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, tearDown, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

WalkingRouteFormatterTest

public WalkingRouteFormatterTest()
Method Detail

setUp

protected void setUp()
Overrides:
setUp in class TestCase

testShortDirections

public void testShortDirections()
                         throws IOException
Test simple directions with one distance and one origHeading.

Throws:
IOException

testTurning

public void testTurning()
Test turning directions, with different origHeadings.


testDistance

public void testDistance()
Test rounding distance, specifically if it rounds up to 0.1 and rounds down to 0.0. Should compute time before rounding.


testRepeatedSegment

public void testRepeatedSegment()
Two step route with one geo feature.


testLongRoute

public void testLongRoute()
Long route with no repeats.


testRepeatedRoute

public void testRepeatedRoute()
Just like long route, but different makeup of geosegements.