"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "modules/library/referencing/src/test/java/org/geotools/referencing/factory/URN_ParserTest.java" between
geotools-24.0-project.zip and geotools-24.1-project.zip

About: GeoTools (The Open Source Java GIS Toolkit) is a Java code library which provides standards compliant methods for the manipulation of geospatial data.

URN_ParserTest.java  (geotools-24.0-project):URN_ParserTest.java  (geotools-24.1-project)
skipping to change at line 52 skipping to change at line 52
/** Parses a valid URN without version. */ /** Parses a valid URN without version. */
@Test @Test
public void testParseWithoutVersion() throws NoSuchAuthorityCodeException { public void testParseWithoutVersion() throws NoSuchAuthorityCodeException {
final URN_Parser parser = URN_Parser.buildParser("urn:ogc:def:CRS:EPSG:4 326"); final URN_Parser parser = URN_Parser.buildParser("urn:ogc:def:CRS:EPSG:4 326");
assertEquals("crs", parser.type.name); assertEquals("crs", parser.type.name);
assertEquals("EPSG", parser.authority); assertEquals("EPSG", parser.authority);
assertNull(parser.version); assertNull(parser.version);
assertEquals("4326", parser.code); assertEquals("4326", parser.code);
assertEquals("EPSG:4326", parser.getAuthorityCode()); assertEquals("EPSG:4326", parser.getAuthorityCode());
final URN_Parser emptyVersionParser = URN_Parser.buildParser("urn:ogc:de
f:crs:EPSG::4326");
emptyVersionParser.toString();
assertEquals("crs", emptyVersionParser.type.name);
assertEquals("EPSG", emptyVersionParser.authority);
assertNull(emptyVersionParser.version);
assertEquals("4326", emptyVersionParser.code);
assertEquals("EPSG:4326", emptyVersionParser.getAuthorityCode());
} }
/** Parses an invalid URN. */ /** Parses an invalid URN. */
@Test @Test
public void testInvalidParse() { public void testInvalidParse() {
final String urn = "urn:ogcx:def:CRS:EPSG:6.8:4326"; final String urn = "urn:ogcx:def:CRS:EPSG:6.8:4326";
try { try {
URN_Parser.buildParser(urn); URN_Parser.buildParser(urn);
fail(); fail();
} catch (NoSuchAuthorityCodeException e) { } catch (NoSuchAuthorityCodeException e) {
 End of changes. 1 change blocks. 
0 lines changed or deleted 9 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)