1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-01 13:09:50 +00:00

oeqa/core/decorator/__init__.py: use 'cls' instead of 'obj'

Use 'cls' instead of 'obj' to better reflect that registerDecorator
actually serves as a class decorator.

(From OE-Core rev: e06e4c859e8be5225d80806a2ebe175f0b152fe1)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Chen Qi
2018-06-01 13:03:01 +08:00
committed by Richard Purdie
parent a233b59fb0
commit 93bbc30fb9
+3 -3
View File
@@ -6,9 +6,9 @@ from abc import abstractmethod, ABCMeta
decoratorClasses = set() decoratorClasses = set()
def registerDecorator(obj): def registerDecorator(cls):
decoratorClasses.add(obj) decoratorClasses.add(cls)
return obj return cls
class OETestDecorator(object, metaclass=ABCMeta): class OETestDecorator(object, metaclass=ABCMeta):
case = None # Reference of OETestCase decorated case = None # Reference of OETestCase decorated