uflacs tests (gtest) can't br run from top-level ffc directory
The uflacs tests that use gtest fail if run from the top-level ffc directory.
It would be handy if this would work - it would make the pipelines testing neater because there was have some path issues when running pytest via python -m pytest foo
.
Comments (12)
-
-
Ok, it fails with
python -m pytest test/uflacs
. -
reporter Could be a different issue from the title of the report.
py.test
andpythin -m pytest
are not the same (despite what is written in the pytest docs). They handle paths differently. -
-
assigned issue to
-
assigned issue to
-
I'm trying to make the paths consistently absolute, there were a couple of exceptions.
-
reporter This I've seen is related to PYTHONPATH, at least with pipelines where tests are run as root.
-
This is weird:
ffc.backends.ufc.get_include_path()
returns/home/martinal/dev/fenics-dev/ffc/test/uflacs/crosslanguage/ffc/backends/ufc
when run fromtest/uflacs/conftest.py
-
ffc.__main__
does funny things withsys.path
, but removing that didn't help... -
In
get_include_dir
:In [1]: __file__ Out[1]: 'ffc/backends/ufc/__init__.py' In [2]: os.path.abspath(__file__) Out[2]: '/home/martinal/dev/fenics-dev/ffc/test/uflacs/crosslanguage/ffc/backends/ufc/__init__.py'
-
Why is file not absolute?
-
Fix on the way.
-
- changed status to resolved
- Log in to comment
works here?