1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-01-31 10:11:17 +00:00

fw/instrument: derive Instrument from TargetedPlugin

Change Instrument to derive from TargetedPlugin rather than Plugin,
which it should have been all along.
This commit is contained in:
Sergei Trofimov 2020-02-04 12:31:08 +00:00 committed by Marc Bonnici
parent 79dec810f3
commit fe50d75858

View File

@ -104,7 +104,7 @@ import inspect
from collections import OrderedDict from collections import OrderedDict
from wa.framework import signal from wa.framework import signal
from wa.framework.plugin import Plugin from wa.framework.plugin import TargetedPlugin
from wa.framework.exception import (TargetNotRespondingError, TimeoutError, # pylint: disable=redefined-builtin from wa.framework.exception import (TargetNotRespondingError, TimeoutError, # pylint: disable=redefined-builtin
WorkloadError, TargetError) WorkloadError, TargetError)
from wa.utils.log import log_error from wa.utils.log import log_error
@ -421,14 +421,13 @@ def get_disabled():
return [i for i in installed if not i.is_enabled] return [i for i in installed if not i.is_enabled]
class Instrument(Plugin): class Instrument(TargetedPlugin):
""" """
Base class for instrument implementations. Base class for instrument implementations.
""" """
kind = "instrument" kind = "instrument"
def __init__(self, target, **kwargs): def __init__(self, *args, **kwargs):
super(Instrument, self).__init__(**kwargs) super(Instrument, self).__init__(*args, **kwargs)
self.target = target
self.is_enabled = True self.is_enabled = True
self.is_broken = False self.is_broken = False