fix(pytest_gcov): properly extract file path from the gcov output

This commit is contained in:
Erhan Kurubas 2023-10-11 23:34:27 +02:00
parent 5d1acfc44f
commit 14a631880c

View File

@ -48,7 +48,7 @@ def test_gcov(dut: IdfDut, openocd: OpenOcd) -> None:
for expect in expect_lines[:]:
if expect in line:
if expect.endswith('.gcda'): # check file exists
file_path = line.split()[-1].strip("'")
file_path = line.split()[3].strip("'")
assert os.path.isfile(file_path)
expect_lines.remove(expect)