test: twister: testplan.py use normpath

when load test plan it is possible the plan is built in another os
so the case key would be
'samples/hello_world/samples.baseic.hello_world'
but the testsuite is scaned in current os may in window
and the key is like
'samples\\hello_world\\samples.baseic.hello_world'

so update the uniq path with only backslash in path

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
This commit is contained in:
Hake Huang 2023-10-24 00:39:25 +08:00 committed by Carles Cufí
commit dbed251249

View file

@ -450,7 +450,7 @@ class TestSuite(DisablePyTestCollectionMixin):
relative_ts_root = ""
# workdir can be "."
unique = os.path.normpath(os.path.join(relative_ts_root, workdir, name))
unique = os.path.normpath(os.path.join(relative_ts_root, workdir, name)).replace(os.sep, '/')
return unique
@staticmethod