gml3 unit test failures in Eclipse caused by EPSG versioning support --------------------------------------------------------------------
Key: GEOT-3112 URL: http://jira.codehaus.org/browse/GEOT-3112 Project: GeoTools Issue Type: Bug Components: core referencing, ext xml-xsd Reporter: Ben Caradoc-Davies Two gt-xsd-gml3 unit tests fail in Eclipse only. The tests are EnvelopeTypeBindingTest and PointTypeBindingTest. The failures are the same, and appear as an incorrect srsName in an encoded geometry type. The underlying cause appears to be support for versioning of EPSG codes. Because of its different dependency model, Eclipse gets a gt-epsk-wkt test dependency that maven does not, and so gets a CRSAuthorityFactory implementation not used in maven tests (seeing this in maven requires sprinkling System.out breadcrumbs in the code). The EPSG versioning support seems to give the dodgy gt-epsg-wkt EPSGCRSAuthorityFactory priority over the production CRSAuthorityFactory implementation that ends up being used by maven tests. Commenting out line 306 of URN_AuthorityFactory [the "new AllAuthoritiesFactory(hints)," line in createVersionedFactory()] causes the gt-xsd-gml3 unit tests to pass! I suspect this disables versioning support. I do not know enough about referencing to fix this properly. The referencing module is ... er ... full-featured. {code} junit.framework.ComparisonFailure: null expected:<[urn:x-ogc:def:crs:EPSG:]4326> but was:<[http://www.opengis.net/gml/srs/epsg.xml#]4326> at junit.framework.Assert.assertEquals(Assert.java:81) at junit.framework.Assert.assertEquals(Assert.java:87) at org.geotools.gml3.bindings.EnvelopeTypeBindingTest.testEncode(EnvelopeTypeBindingTest.java:42) {code} {code} junit.framework.ComparisonFailure: null expected:<[urn:x-ogc:def:crs:EPSG:]4326> but was:<[http://www.opengis.net/gml/srs/epsg.xml#]4326> at junit.framework.Assert.assertEquals(Assert.java:81) at junit.framework.Assert.assertEquals(Assert.java:87) at org.geotools.gml3.bindings.PointTypeBindingTest.testEncode(PointTypeBindingTest.java:46) {code} -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------------ _______________________________________________ Geotools-devel mailing list Geotools-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-devel