You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/01/10 08:42:36 UTC

[GitHub] [airflow] potiuk commented on issue #20453: The "has_calls" is used in place of "assert_has_calls" in a few places

potiuk commented on issue #20453:
URL: https://github.com/apache/airflow/issues/20453#issuecomment-1008649769


   Have you tried to run `breeze` to run the tests? https://github.com/apache/airflow/blob/main/BREEZE.rst 
   
   Airflow has docker-compose based development environment that is the mirror of what is used in CI. Essentially it should be as easy as:
   
   ```
   ./breeze
   ```
   
   This should drop you (after a while of getting images and starting docker compose) into ./breeze shell (which is bash inside docler-compose airlfow image). Then immediately you should be able to run (you can auto-complete the tests with TAB):
   
   ```
   pytest test/providers/google/...
   ```
   
   and it should run the tests. The first time it will initialize the db and create all the necessary connections, Also while you are in the breeze shell you can run ``airflow db reset`` and it should reset the db ``airflow db init`` will fill the db with default connections. 
   
   By default it will use sqlite database, but you can also do (--db-reset is optional - the first ime you run it, the database should be "fresh", --db-reset is needed if you need to reset the DB from scratch):
   
   ```
   airflow breeze --backend postgres --db-reset
   ```
   or
   
   ```
   airflow breeze --backend mysql --db-reset
   ```
   
   or even:
   
   ```
   airflow breeze --backend postgres --python 3.9 --db-reset
   ```
   
   If you need to run tests with a different python version.
   
   I hope it will be helpful
   
   


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org