Skip to content

Commit 43ffc76

Browse files
committed
resolve ROBOT_LIBRARY_SCOPE typing issue
1 parent 35d6d3e commit 43ffc76

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

robotmbt/suitereplacer.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,18 +35,15 @@
3535
from .suitedata import Suite, Scenario, Step
3636
from .suiteprocessors import SuiteProcessors
3737
from robot.api import logger
38-
from robot.api.deco import keyword
38+
from robot.api.deco import library, keyword
3939
from typing import Any, Literal
4040
from robot.libraries.BuiltIn import BuiltIn
4141
Robot = BuiltIn()
4242

4343

44+
@library(scope="GLOBAL", listener='SELF')
4445
class SuiteReplacer:
45-
ROBOT_LIBRARY_SCOPE: Literal['GLOBAL'] = 'GLOBAL'
46-
ROBOT_LISTENER_API_VERSION: Literal[3] = 3
47-
4846
def __init__(self, processor: str = 'process_test_suite', processor_lib: str | None = None):
49-
self.ROBOT_LIBRARY_LISTENER = self
5047
self.current_suite: robot.model.TestSuite | None = None
5148
self.robot_suite: robot.model.TestSuite | None = None
5249
self.processor_lib_name: str | None = processor_lib

0 commit comments

Comments
 (0)