kopia lustrzana https://github.com/glidernet/python-ogn-client
Test unknown dstcall
rodzic
a580481590
commit
b309cfe805
|
@ -6,7 +6,7 @@ from datetime import datetime
|
||||||
from time import sleep
|
from time import sleep
|
||||||
|
|
||||||
from ogn.parser.parse import parse
|
from ogn.parser.parse import parse
|
||||||
from ogn.parser.exceptions import AprsParseError
|
from ogn.parser.exceptions import AprsParseError, OgnParseError
|
||||||
|
|
||||||
|
|
||||||
class TestStringMethods(unittest.TestCase):
|
class TestStringMethods(unittest.TestCase):
|
||||||
|
@ -63,6 +63,10 @@ class TestStringMethods(unittest.TestCase):
|
||||||
with self.assertRaises(AprsParseError):
|
with self.assertRaises(AprsParseError):
|
||||||
parse("Lachens>APRS,TCPIwontbeavalidstring")
|
parse("Lachens>APRS,TCPIwontbeavalidstring")
|
||||||
|
|
||||||
|
def test_fail_bad_dstcall(self):
|
||||||
|
with self.assertRaises(OgnParseError):
|
||||||
|
parse("EPZR>WTFDSTCALL,TCPIP*,qAC,GLIDERN1:>093456h this is a comment")
|
||||||
|
|
||||||
def test_v026_chile(self):
|
def test_v026_chile(self):
|
||||||
# receiver beacons from chile have a APRS position message with a pure user comment
|
# receiver beacons from chile have a APRS position message with a pure user comment
|
||||||
message = parse("VITACURA1>APRS,TCPIP*,qAC,GLIDERN4:/201146h3322.79SI07034.80W&/A=002329 Vitacura Municipal Aerodrome, Club de Planeadores Vitacura", reference_date=datetime(2015, 1, 1))
|
message = parse("VITACURA1>APRS,TCPIP*,qAC,GLIDERN4:/201146h3322.79SI07034.80W&/A=002329 Vitacura Municipal Aerodrome, Club de Planeadores Vitacura", reference_date=datetime(2015, 1, 1))
|
||||||
|
|
Ładowanie…
Reference in New Issue