org.eclipse.emf.test.edit.provider
Class TypeSearchTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.eclipse.emf.test.edit.provider.TypeSearchTest
All Implemented Interfaces:
junit.framework.Test

public class TypeSearchTest
extends junit.framework.TestCase

A test case that demonstrates how getReachableObjectsOfType works. This test case looks for different objects that are reachable in the graph given their type. The test case uses a large dataset and demonstrates BUG #161744;


Field Summary
static int DATASETSIZE
           
 
Constructor Summary
TypeSearchTest(java.lang.String name)
           
 
Method Summary
protected  void setUp()
          Setup the test case
static junit.framework.Test suite()
           
 void testFindFirstObject()
          Looks to see if it can find the first node in the list.
 void testFindLastObject()
          Looks to see if it can find the last node in the list.
 void testFindMultiType()
          See if we can find the 3501 po Objects
 void testFindMultiType2()
          See if we can find the 350 item Objects
 void testFindNoType()
          Starting from the otherObject we can't get anywhere.
 void testFindSingleType()
          See if we can find the 1 otherObject
 void testFindWithSuperTypes()
          This test cases tests the reachable objects using their supertype.
 
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, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DATASETSIZE

public static final int DATASETSIZE
See Also:
Constant Field Values
Constructor Detail

TypeSearchTest

public TypeSearchTest(java.lang.String name)
Method Detail

suite

public static junit.framework.Test suite()

setUp

protected void setUp()
              throws java.lang.Exception
Setup the test case

Overrides:
setUp in class junit.framework.TestCase
Throws:
java.lang.Exception

testFindMultiType

public void testFindMultiType()
                       throws java.lang.Exception
See if we can find the 3501 po Objects

Throws:
java.lang.Exception

testFindMultiType2

public void testFindMultiType2()
                        throws java.lang.Exception
See if we can find the 350 item Objects

Throws:
java.lang.Exception

testFindWithSuperTypes

public void testFindWithSuperTypes()
                            throws java.lang.Exception
This test cases tests the reachable objects using their supertype. Both the po objects and the items were of type "superClass".

Throws:
java.lang.Exception

testFindSingleType

public void testFindSingleType()
                        throws java.lang.Exception
See if we can find the 1 otherObject

Throws:
java.lang.Exception

testFindNoType

public void testFindNoType()
                    throws java.lang.Exception
Starting from the otherObject we can't get anywhere. See if this works. i.e. we should get no po objects from here!

Throws:
java.lang.Exception

testFindFirstObject

public void testFindFirstObject()
                         throws java.lang.Exception
Looks to see if it can find the first node in the list. The first node was a different type, so it should be found if we search by type.

Throws:
java.lang.Exception

testFindLastObject

public void testFindLastObject()
                        throws java.lang.Exception
Looks to see if it can find the last node in the list. The last node was a different type, so it should be found if we search by type.

Throws:
java.lang.Exception

Copyright 2001-2006 IBM Corporation and others.
All Rights Reserved.