Beispiel #1
0
def test_extact_vtg_handles_empty_values():
    gps = GPSService()
    msg = "$GNVTG,,,,,,,,,N*2E"
    data = pynmea2.parse(msg)
    info = gps.extract_vtg(data)
    assert info.speed == 0.0
Beispiel #2
0
def test_extact_vtg_handles_empty_values():
    gps = GPSService()
    msg = "$GNVTG,,,,,,,,,N*2E"
    data = pynmea2.parse(msg)
    info = gps.extract_vtg(data)
    assert info.speed == 0.0
Beispiel #3
0
def test_extact_vtg_returns_correct_info():
    gps = GPSService()
    msg = "$GNVTG,,T,,M,0.148,N,0.274,K,A*31"
    data = pynmea2.parse(msg)
    info = gps.extract_vtg(data)
    assert info.speed == 0.274
Beispiel #4
0
def test_extact_vtg_returns_correct_info():
    gps = GPSService()
    msg = "$GNVTG,,T,,M,0.148,N,0.274,K,A*31"
    data = pynmea2.parse(msg)
    info = gps.extract_vtg(data)
    assert info.speed == 0.274