potiuk commented on pull request #20913: URL: https://github.com/apache/airflow/pull/20913#issuecomment-1020918102
Ah.. This can be fixed easily. The problem is that Pytest tries to load "tests/conftest.py" automatically. This is the way how pytest can automatically load configuration for tests. And Pytests will try to load it automatically - trying to load them from the current directory: https://docs.pytest.org/en/6.2.x/writing_plugins.html#plugin-discovery-order-at-tool-startup By default commands in `ci.yml` are executed in main directory of the project. so it will actually try to run the tests/conftest.py automatically (and this is where it requires freezegun, sqlalchemy and probably more). The solution is easy. Change the working directory of the pytest command https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun ``` - name: ..... run: pytest -m test_examples_of_prod_image_building.py working-directory: ./docker-examples ``` -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
