|
Description:
|
Using JDK 1.6 I am able to build the geotiff module. But if I switch to JDK 1.7 (u13) I got a failure in org.geotools.gce.geotiff.GeoTiffReaderTest in prjOverrideTesting1.
To check I introduced some System.outs in the test method:
final File prj= TestData.file(GeoTiffReaderTest.class, "override/sample.prj");
final CoordinateReferenceSystem crs_=new PrjFileReader(new FileInputStream(prj).getChannel()).getCoordinateReferenceSystem();
System.out.println(crs);
System.out.println(crs_);
System.out.println(CRS.equalsIgnoreMetadata(crs, crs_));
assertTrue(CRS.equalsIgnoreMetadata(crs, crs_));
for crs I got the output:
PROJCS["unnamed",
GEOGCS["GCS Name = GRS 1980(IUGG, 1980)",
DATUM["Datum = unknown",
SPHEROID["Ellipsoid = GRS80", 6378137.0, 298.257222101]],
PRIMEM["Greenwich", 0.0],
UNIT["degree", 0.017453292519943295],
AXIS["Geodetic longitude", EAST],
AXIS["Geodetic latitude", NORTH]],
PROJECTION["Transverse_Mercator"],
PARAMETER["central_meridian", 21.0],
PARAMETER["latitude_of_origin", 0.0],
PARAMETER["scale_factor", 0.9999],
PARAMETER["false_easting", 7500000.0],
PARAMETER["false_northing", 0.0],
UNIT["m", 1.0],
AXIS["Easting", EAST],
AXIS["Northing", NORTH]]
and for crs_:
PROJCS["KosovaRef01",
GEOGCS["GCS_GRS_1980",
DATUM["D_ETRS_89",
SPHEROID["GRS_1980", 6378137.0, 298.257222101]],
PRIMEM["Greenwich", 0.0],
UNIT["degree", 0.017453292519943295],
AXIS["Longitude", EAST],
AXIS["Latitude", NORTH]],
PROJECTION["Transverse_Mercator"],
PARAMETER["central_meridian", 21.0],
PARAMETER["latitude_of_origin", 0.0],
PARAMETER["scale_factor", 0.9999],
PARAMETER["false_easting", 7500000.0],
PARAMETER["false_northing", 0.0],
UNIT["m", 1.0],
AXIS["x", EAST],
AXIS["y", NORTH]]
which are different. Therefore the test must fail. But this is only the case for JDK1.7 non Debug mode.
Using JDK 1.6 both crs - outputs are identical and using JDK 1.7 in Debug - mode the outputs are identical as well.
Tobias
|