twisted.positioning.test.test_nmea.FixerTestMixin(object)
class documentationtwisted.positioning.test.test_nmea
(View In Hierarchy)
Known subclasses: twisted.positioning.test.test_nmea.AltitudeFixerTests, twisted.positioning.test.test_nmea.CoordinateFixerTests, twisted.positioning.test.test_nmea.DatestampFixerTests, twisted.positioning.test.test_nmea.InvalidFixTests, twisted.positioning.test.test_nmea.PositionErrorFixerTests, twisted.positioning.test.test_nmea.SpeedFixerTests, twisted.positioning.test.test_nmea.TimestampFixerTests, twisted.positioning.test.test_nmea.ValidFixTests, twisted.positioning.test.test_nmea.VariationFixerTests
Mixin for tests for the fixers on nmea.NMEAAdapter
that adapt from NMEA-specific notations to generic Python objects.
Instance Variable | adapter | The NMEA adapter. (type: nmea.NMEAAdapter ) |
Method | setUp | Undocumented |
Method | _fixerTest | A generic adapter fixer test. |
A generic adapter fixer test.
Creates a sentence from the sentenceData
and sends that to
the adapter. If exceptionClass
is not passed, this is assumed
to work, and expected
is compared with the adapter's internal
state. Otherwise, passing the sentence to the adapter is checked to raise
exceptionClass
.
Parameters | sentenceData | Raw sentence content. (type: dict mapping str to str ) |
expected | The expected state of the adapter. (type: dict or None ) | |
exceptionClass | The exception to be raised by the adapter. (type: subclass of Exception ) |