From a1867986e71676a0a9266d437b1927fde7cf403c Mon Sep 17 00:00:00 2001 From: Lakshmi Narayanan Sreethar Date: Mon, 22 Jan 2024 11:22:34 +0530 Subject: [PATCH] test.py: deduce correct path for unit tests when built with cmake Fix the path deduction for unit test executables when the source code is built with cmake. Fixes #16906 Signed-off-by: Lakshmi Narayanan Sreethar Closes scylladb/scylladb#16907 --- test.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test.py b/test.py index 7b86890afe..e5fe4f5a86 100755 --- a/test.py +++ b/test.py @@ -635,7 +635,7 @@ class UnitTest(Test): def __init__(self, test_no: int, shortname: str, suite, args: str) -> None: super().__init__(test_no, shortname, suite) - self.path = path_to(self.mode, "test", self.name) + self.path = path_to(self.mode, "test", suite.name, shortname.split('.')[0]) self.args = shlex.split(args) + UnitTest.standard_args if self.mode == "coverage": self.env.update(coverage.env(self.path))