|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
ObjectTestCase
ObjectFactoryTest
public class ObjectFactoryTest
Tests the creation of referencing objects from the object factories given at construction time.
In order to specify their factories and run the tests in a JUnit framework, implementors can define a subclass as below:
import org.junit.runner.RunWith;
import org.junit.runners.JUnit4;
import org.opengis.test.referencing.ObjectFactoryTest;
@RunWith(JUnit4.class)
public class MyTest extends ObjectFactoryTest {
public MyTest() {
super(new MyDatumFactory(), new MyCSFactory(), new MyCRSFactory(), new MyOpFactory());
}
}
Alternatively this test class can also be used directly in the TestSuite,
which combine every tests defined in the GeoAPI conformance module.
AuthorityFactoryTest,
TestSuite| Field Summary | |
|---|---|
protected CoordinateOperationFactory |
copFactory
Factory to use for building Conversion instances, or null if none. |
protected CRSFactory |
crsFactory
Factory to use for building CoordinateReferenceSystem instances, or null if none. |
protected CSFactory |
csFactory
Factory to use for building CoordinateSystem instances, or null if none. |
protected DatumFactory |
datumFactory
Factory to use for building Datum instances, or null if none. |
| Fields inherited from class TestCase |
|---|
configurationTip, listener, NO_FACTORY, validators |
| Constructor Summary | |
|---|---|
ObjectFactoryTest(DatumFactory datumFactory,
CSFactory csFactory,
CRSFactory crsFactory,
CoordinateOperationFactory copFactory)
Creates a new test using the given factories. |
|
| Method Summary | |
|---|---|
static List<Factory[]> |
factories()
Returns a default set of factories to use for running the tests. |
void |
testGeocentric()
Tests the creation of a geocentric CRS. |
void |
testProjected3D()
Tests the creation of a projected CRS with vertical height. |
void |
testWGS84_3D()
Tests the creation of the WGS84 CRS, and verifies that the axes are in the given (longitude, latitude) order. |
void |
testWGS84()
Tests the creation of the EPSG:4326 GeographicCRS. |
| Methods inherited from class TestCase |
|---|
addTestListener, configuration, factories, factories, getEnabledFlags, removeTestListener |
| Methods inherited from class Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final DatumFactory datumFactory
Datum instances, or null if none.
protected final CSFactory csFactory
CoordinateSystem instances, or null if none.
protected final CRSFactory crsFactory
CoordinateReferenceSystem instances, or null if none.
protected final CoordinateOperationFactory copFactory
Conversion instances, or null if none.
| Constructor Detail |
|---|
public ObjectFactoryTest(DatumFactory datumFactory,
CSFactory csFactory,
CRSFactory crsFactory,
CoordinateOperationFactory copFactory)
null,
then the tests which depend on it will be skipped.
datumFactory - Factory for creating Datum instances.csFactory - Factory for creating CoordinateSystem instances.crsFactory - Factory for creating CoordinateReferenceSystem instances.copFactory - Factory for creating Conversion instances.| Method Detail |
|---|
public static List<Factory[]> factories()
TestCase.factories(Class[]) javadoc.
ObjectFactoryTest constructor.
public void testWGS84()
throws FactoryException
GeographicCRS. This method wraps the
object factories in an PseudoEpsgFactory instance, then delegates to the
AuthorityFactoryTest.testWGS84() method.
FactoryException - if a factory fails to create a referencing object.
public void testWGS84_3D()
throws FactoryException
FactoryException - if a factory fails to create a referencing object.
public void testGeocentric()
throws FactoryException
FactoryException - if a factory fails to create a referencing object.
public void testProjected3D()
throws FactoryException
FactoryException - if a factory fails to create a referencing object.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||