Tests: convert even more left-over type hint to type comment
[lttng-tools.git] / tests / utils / lttngtest / environment.py
index 282e95643c33a6ece9cd2f815bc1d28f5f6f69f0..42b0a61b9b35930d9474fa529390e9181382ff6f 100644 (file)
@@ -189,11 +189,13 @@ class WaitTraceTestApplication:
 
 class TraceTestApplication:
     """
-    Create an application to trace.
+    Create an application that emits events as soon as it is launched. In most
+    scenarios, it is preferable to use a WaitTraceTestApplication.
     """
 
-    def __init__(self, binary_path: pathlib.Path, environment: "Environment"):
-        self._environment: Environment = environment
+    def __init__(self, binary_path, environment):
+        # type: (pathlib.Path, Environment)
+        self._environment = environment  # type: Environment
         self._has_returned = False
 
         test_app_env = os.environ.copy()
@@ -204,11 +206,12 @@ class TraceTestApplication:
 
         test_app_args = [str(binary_path)]
 
-        self._process: subprocess.Popen = subprocess.Popen(
+        self._process = subprocess.Popen(
             test_app_args, env=test_app_env
-        )
+        )  # type: subprocess.Popen
 
-    def wait_for_exit(self) -> None:
+    def wait_for_exit(self):
+        # type: () -> None
         if self._process.wait() != 0:
             raise RuntimeError(
                 "Test application has exit with return code `{return_code}`".format(
@@ -412,9 +415,8 @@ class _Environment(logger._Logger):
             self,
         )
 
-    def launch_trace_test_constructor_application(
-        self
-    ) -> TraceTestApplication:
+    def launch_trace_test_constructor_application(self):
+        # type () -> TraceTestApplication
         """
         Launch an application that will trace from within constructors.
         """
This page took 0.024574 seconds and 4 git commands to generate.