Skip to content
Commit 9fb77fcf authored by Pavel Labath's avatar Pavel Labath
Browse files

Fix test rerun logic

result_formatter used inspect.getfile() to get the python file name, which returned "*.pyc" if
the bytecode file was present. This resulted in files being displayed with the wrong extension,
and more critically, would confuse the rerun logic because it would try to rerun the pyc file
(which resulted in an empty rerun list as unittest refused to run those).

Fix: use inspect.getsourcefile() instead.

I am not sure why does was not an issue before. I can only assume that some system update
tricked python into producing bytecode files more aggressively.

llvm-svn: 266192
parent 855d97e3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment