LogAnalyzer: LogAnalyzer: make all subclasses of Test call their parent __init()__ function when overriding that function. This is the way of Python.

This commit is contained in:
Aaron Curtis 2014-06-27 13:11:23 -10:00 committed by Craig Elder
parent f0cf612372
commit 9dbfa40afd
13 changed files with 13 additions and 0 deletions

View File

@ -7,6 +7,7 @@ class TestBrownout(Test):
'''test for a log that has been truncated in flight'''
def __init__(self):
Test.__init__(self)
self.name = "Brownout"
def run(self, logdata, verbose):

View File

@ -8,6 +8,7 @@ class TestCompass(Test):
'''test for compass offsets and throttle interference'''
def __init__(self):
Test.__init__(self)
self.name = "Compass"
def run(self, logdata, verbose):

View File

@ -10,6 +10,7 @@ class TestDualGyroDrift(Test):
'''test for gyro drift between dual IMU data'''
def __init__(self):
Test.__init__(self)
self.name = "Gyro Drift"
self.enable = False

View File

@ -6,6 +6,7 @@ class TestDupeLogData(Test):
'''test for duplicated data in log, which has been happening on PX4/Pixhawk'''
def __init__(self):
Test.__init__(self)
self.name = "Dupe Log Data"
def __matchSample(self, sample, sampleStartIndex, logdata):

View File

@ -6,6 +6,7 @@ class TestEmpty(Test):
'''test for empty or near-empty logs'''
def __init__(self):
Test.__init__(self)
self.name = "Empty"
def run(self, logdata, verbose):

View File

@ -7,6 +7,7 @@ class TestEvents(Test):
# TODO: need to check for vehicle-specific codes
def __init__(self):
Test.__init__(self)
self.name = "Event/Failsafe"
def run(self, logdata, verbose):

View File

@ -6,6 +6,7 @@ class TestGPSGlitch(Test):
'''test for GPS glitch reporting or bad GPS data (satellite count, hdop)'''
def __init__(self):
Test.__init__(self)
self.name = "GPS"
def run(self, logdata, verbose):

View File

@ -8,6 +8,7 @@ class TestParams(Test):
'''test for any obviously bad parameters in the config'''
def __init__(self):
Test.__init__(self)
self.name = "Parameters"

View File

@ -6,6 +6,7 @@ class TestPerformance(Test):
'''check performance monitoring messages (PM) for issues with slow loops, etc'''
def __init__(self):
Test.__init__(self)
self.name = "PM"
def run(self, logdata, verbose):

View File

@ -9,6 +9,7 @@ class TestPitchRollCoupling(Test):
# TODO: currently we're only checking for roll/pitch outside of max lean angle, will come back later to analyze roll/pitch in versus out values
def __init__(self):
Test.__init__(self)
self.name = "Pitch/Roll"
self.enable = True # TEMP

View File

@ -6,6 +6,7 @@ class TestThrust(Test):
'''test for sufficient thrust (copter only for now)'''
def __init__(self):
Test.__init__(self)
self.name = "Thrust"
def run(self, logdata, verbose):

View File

@ -8,6 +8,7 @@ class TestVCC(Test):
'''test for VCC within recommendations, or abrupt end to log in flight'''
def __init__(self):
Test.__init__(self)
self.name = "VCC"
def run(self, logdata, verbose):

View File

@ -8,6 +8,7 @@ class TestVibration(Test):
'''test for accelerometer vibration (accX/accY/accZ) within recommendations'''
def __init__(self):
Test.__init__(self)
self.name = "Vibration"