mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-21 23:33:57 -04:00
Tools: common.py : make some method statics
This commit is contained in:
parent
6c43ab27c1
commit
065a459df8
@ -110,12 +110,14 @@ class AutoTest(ABC):
|
||||
self.viewerip = viewerip
|
||||
self.use_map = use_map
|
||||
|
||||
def progress(self, text):
|
||||
@staticmethod
|
||||
def progress(text):
|
||||
"""Display autotest progress text."""
|
||||
print("AUTOTEST: " + text)
|
||||
|
||||
# following two functions swiped from autotest.py:
|
||||
def buildlogs_dirpath(self):
|
||||
@staticmethod
|
||||
def buildlogs_dirpath():
|
||||
return os.getenv("BUILDLOGS", util.reltopdir("../buildlogs"))
|
||||
|
||||
def buildlogs_path(self, path):
|
||||
@ -299,7 +301,8 @@ class AutoTest(ABC):
|
||||
self.mavproxy.send('map set showgpspos 0\n')
|
||||
self.mavproxy.send('map set showsimpos 0\n')
|
||||
|
||||
def mission_count(self, filename):
|
||||
@staticmethod
|
||||
def mission_count(filename):
|
||||
"""Load a mission from a file and return number of waypoints."""
|
||||
wploader = mavwp.MAVWPLoader()
|
||||
wploader.load(filename)
|
||||
|
Loading…
Reference in New Issue
Block a user