comparison tests/run-tests.py @ 47182:dff19fe2973c stable

run-tests: fix whitelist/blacklist with directories on Windows The file name is resolved with `os.path.relpath()` in the `Test` constructor, which yields `\` on Windows. That doesn't match the `/` separator when using MSYS tools to build the list, and it isn't obvious that this is the problem because directory separators can mostly be used interchangeably. The `--test-list` argument already seems to be properly handled.
author Matt Harbison <matt_harbison@yahoo.com>
date Wed, 05 May 2021 17:47:30 -0400
parents 6e0af81c43b2
children bcafcd779d2e
comparison
equal deleted inserted replaced
47181:6e0af81c43b2 47182:dff19fe2973c
359 continue 359 continue
360 360
361 for line in f.readlines(): 361 for line in f.readlines():
362 line = line.split(b'#', 1)[0].strip() 362 line = line.split(b'#', 1)[0].strip()
363 if line: 363 if line:
364 entries[line] = filename 364 # Ensure path entries are compatible with os.path.relpath()
365 entries[os.path.normpath(line)] = filename
365 366
366 f.close() 367 f.close()
367 return entries 368 return entries
368 369
369 370