Changeset 9380 in josm
- Timestamp:
- 2016-01-10T02:54:19+01:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/io/GpxReaderTest.java
r9378 r9380 5 5 import static org.junit.Assert.assertTrue; 6 6 7 import java.io.ByteArrayInputStream; 7 8 import java.io.File; 8 9 import java.io.FileInputStream; 10 import java.nio.charset.StandardCharsets; 9 11 import java.util.List; 10 12 11 import org.apache.tools.ant.filters.StringInputStream;12 13 import org.junit.Test; 13 14 import org.openstreetmap.josm.data.coor.LatLon; … … 42 43 } 43 44 45 /** 46 * Tests invalid data. 47 * @throws Exception always SAXException 48 */ 44 49 @Test(expected = SAXException.class) 45 50 public void testException() throws Exception { 46 new GpxReader(new StringInputStream("--foo--bar--")).parse(true);51 new GpxReader(new ByteArrayInputStream("--foo--bar--".getBytes(StandardCharsets.UTF_8))).parse(true); 47 52 } 48 53 }
Note:
See TracChangeset
for help on using the changeset viewer.