| org.geotools.data.shapefile.TestCaseSupport
All known Subclasses: org.geotools.data.shapefile.ServiceTest, org.geotools.data.shapefile.ShapefileTest, org.geotools.data.shapefile.PrjFileTest, org.geotools.data.shapefile.DbaseFileTest, org.geotools.data.shapefile.ShapefileReadWriteTest, org.geotools.data.shapefile.ShapefileDataStoreTest, org.geotools.data.shapefile.shp.PolygonHandlerTest,
TestCaseSupport | public class TestCaseSupport extends TestCase (Code) | | Base class for test suite. This class is not abstract for the purpose of
TestCaseSupportTest , but should not be instantiated otherwise.
It should be extented (which is why the constructor is protected).
Note: a nearly identical copy of this file exists in the
ext/shape module.
version: $Id: TestCaseSupport.java 24788 2007-03-17 18:01:31Z aaime $ author: Ian Schneider author: Martin Desruisseaux |
Constructor Summary | |
protected | TestCaseSupport(String name) Creates a new instance of
TestCaseSupport with the given name. |
Method Summary | |
protected File | copyShapefiles(String name) Copies the specified shape file into the
test-data directory, together with its
sibling (
.dbf ,
.shp ,
.shx and
.prj files). | protected Feature | firstFeature(FeatureCollection fc) Returns the first feature in the given feature collection. | protected File | getTempFile() Creates a temporary file, to be automatically deleted at the end of the test suite. | protected Geometry | readGeometry(String wktResource) Read a geometry of the given name.
Parameters: wktResource - The resource name to load, without its .wkt extension. | public static Test | suite(Class c) Returns the test suite for the given class. | protected void | tearDown() Deletes all temporary files created by
TestCaseSupport.getTempFile . |
TestCaseSupport | protected TestCaseSupport(String name) throws IOException(Code) | | Creates a new instance of
TestCaseSupport with the given name.
|
copyShapefiles | protected File copyShapefiles(String name) throws IOException(Code) | | Copies the specified shape file into the
test-data directory, together with its
sibling (
.dbf ,
.shp ,
.shx and
.prj files).
|
getTempFile | protected File getTempFile() throws IOException(Code) | | Creates a temporary file, to be automatically deleted at the end of the test suite.
|
readGeometry | protected Geometry readGeometry(String wktResource) throws IOException(Code) | | Read a geometry of the given name.
Parameters: wktResource - The resource name to load, without its .wkt extension. The geometry. throws: IOException - if reading failed. |
suite | public static Test suite(Class c)(Code) | | Returns the test suite for the given class.
|
|
|