test.calculation
Class GraphTest

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

public class GraphTest
extends junit.framework.TestCase

Test class for the class Graph.

Version:
1
Author:
Potkuri-group

Field Summary
private  int[][] big
          test weather matrices.
(package private) static int BIG_SIZE
          big test map size.
private  general.DataCollection data
          test dataCollection class address.
private  calculation.Vertex[][] graph
          test graph size.
private  calculation.Graph graphClass
          graph class reference.
private  int[][] m1
          test weather matrices.
private  int[][] m2
          test weather matrices.
private  int[][] m3
          test weather matrices.
private  int[][] m4
          test weather matrices.
private  int[][] m5
          test weather matrices.
private  int[][] m6
          test weather matrices.
(package private) static int MAP_SIZE
          test map size.
private  int[][] zero
          test weather matrices.
 
Constructor Summary
GraphTest()
           
 
Method Summary
 void setUp()
          Sets up matrices to use in test methods.
 void tearDown()
          Free resources and memory.
 void testCalculateArcPoints()
          Test to calculate arc points.
 void testGetAirport()
          Test to see if airport vertex can be returned.
 void testGetArcPoints()
          Method to test if arc points are created.
 void testGraph()
          Test for graph creation.
 void testResetGraph()
          Test for resetGraph class.
 void testScale()
          Test to check if scale function works.
 void testSetSafezone()
          test to check if setSafeZone works properly.
 void testUpdate()
          Test for update method.
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, 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, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

big

private int[][] big
test weather matrices.


BIG_SIZE

static final int BIG_SIZE
big test map size.

See Also:
Constant Field Values

data

private general.DataCollection data
test dataCollection class address.


graph

private calculation.Vertex[][] graph
test graph size.


graphClass

private calculation.Graph graphClass
graph class reference.


m1

private int[][] m1
test weather matrices.


m2

private int[][] m2
test weather matrices.


m3

private int[][] m3
test weather matrices.


m4

private int[][] m4
test weather matrices.


m5

private int[][] m5
test weather matrices.


m6

private int[][] m6
test weather matrices.


MAP_SIZE

static final int MAP_SIZE
test map size.

See Also:
Constant Field Values

zero

private int[][] zero
test weather matrices.

Constructor Detail

GraphTest

public GraphTest()
Method Detail

setUp

public void setUp()
           throws java.lang.Exception
Sets up matrices to use in test methods.

Overrides:
setUp in class junit.framework.TestCase
Throws:
java.lang.Exception - if set up doesn't succeed

tearDown

public void tearDown()
Free resources and memory.

Overrides:
tearDown in class junit.framework.TestCase

testCalculateArcPoints

public void testCalculateArcPoints()
Test to calculate arc points.


testGetAirport

public void testGetAirport()
Test to see if airport vertex can be returned.


testGetArcPoints

public void testGetArcPoints()
Method to test if arc points are created.


testGraph

public void testGraph()
Test for graph creation.


testResetGraph

public void testResetGraph()
Test for resetGraph class.


testScale

public void testScale()
Test to check if scale function works.


testSetSafezone

public void testSetSafezone()
test to check if setSafeZone works properly.


testUpdate

public void testUpdate()
Test for update method.