AeroRust / nmea

NMEA 0183 - for communication between marine electronics such as echo sounder, sonars, anemometer, gyrocompass, autopilot, GNSS receivers and many other types of instruments. Defined and controlled by the National Marine Electronics Association (NMEA)
https://crates.io/crates/nmea
Other
57 stars 41 forks source link

Fix failing test #55

Closed elpiel closed 1 year ago

elpiel commented 1 year ago

After a fixed typo for the GNSS types, a failing test appeared that needs to be fixed:

https://github.com/AeroRust/nmea/actions/runs/3074029877/jobs/4966543037

gybrish commented 1 year ago

So the change in mapping from this PR: https://github.com/AeroRust/nmea/commit/c23b4430642ac32b9221e8313164f16da534b702

Changed the mapping for GnssType::Beidou which is causing the test to fail now as the previous GnssType::Beidou is now associated with GnssType::Qzss, is this expected behaviour?

If so it's a relatively simple change to update the data in the test to reflect the new mapping, if this is what indeed what is expected?

elpiel commented 1 year ago

Actually, there was a typo in one of the mappings and when the typo was fixed (a wrongly associated TrackerId) the tests started failing. These are the expected results but that was not the Beidou GNSS, to begin with, so this issue is abouting changing these expected values to Galileo.

https://github.com/AeroRust/nmea/blob/c23b4430642ac32b9221e8313164f16da534b702/tests/file_log_parser.rs#L89-L100

You can also see the excepted (left) vs the actual (right) from the failing test: https://github.com/AeroRust/nmea/actions/runs/3074029877/jobs/4966543037

The talker ids are taken from here and the typo was fixed accordingly to this list: https://gpsd.gitlab.io/gpsd/NMEA.html#_talker_ids

PS: You also have to see if the tests succeed after this, there might be more places that need changing.