uranusjr commented on pull request #15317:
URL: https://github.com/apache/airflow/pull/15317#issuecomment-817323364


   The pytest issue this intends to fix is:
   
   ```
   $ ./breeze tests -- -k test_refresh_py_dag
   ...
   ________________________________________ ERROR collecting test session 
_________________________________________
   /usr/local/lib/python3.6/site-packages/_pytest/config/__init__.py:570: in 
_importconftest
       mod = import_path(conftestpath, mode=importmode)
   /usr/local/lib/python3.6/site-packages/_pytest/pathlib.py:551: in import_path
       raise ImportPathMismatchError(module_name, module_file, path)
   E   _pytest.pathlib.ImportPathMismatchError: ('tests.conftest', 
'/opt/airflow/tests/conftest.py', 
PosixPath('/opt/airflow/chart/tests/conftest.py'))
   ```
   
   This is because on test collection, both `/opt/airflow` (project root) and 
`/opt/airflow/chart` are in `sys.path`, so both 
`/opt/airflow/tests/conftest.py` and `/opt/airflow/chart/tests/conftest.py` 
becomes `tests.conftest` to pytest. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to