diff --git a/src/test/java/net/sf/marineapi/ais/parser/AISMessageFactoryTest.java b/src/test/java/net/sf/marineapi/ais/parser/AISMessageFactoryTest.java index e6fc942d..3e52e0e2 100644 --- a/src/test/java/net/sf/marineapi/ais/parser/AISMessageFactoryTest.java +++ b/src/test/java/net/sf/marineapi/ais/parser/AISMessageFactoryTest.java @@ -32,6 +32,16 @@ public void testCreate() { assertEquals(1, msg.getMessageType()); } + @Test + public void testCreateIssue138() { + String ais = "!AIVDM,1,1,,A,15S0t`001TlGn>TNurwroHgD05;H,0*21"; + AISSentence s = (AISSentence) sf.createParser(ais); + AISMessage msg = amf.create(s); + assertTrue(msg instanceof AISMessage01); + assertEquals(1, msg.getMessageType()); + assertTrue((((AISMessage01) msg).isAccurate())); + } + @Test public void testCreateWithTwo() { AISMessage msg = amf.create(split1, split2); @@ -51,4 +61,6 @@ public void testCreateWithIncorrectOrder() { } } + + }