You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
874 B

5 years ago
  1. version: 2
  2. jobs:
  3. build:
  4. docker:
  5. - image: circleci/python:3.6.1
  6. working_directory: ~/repo
  7. steps:
  8. - checkout
  9. - restore_cache:
  10. keys:
  11. - v1-dependencies-{{ checksum "requirements.txt" }}
  12. # fallback to using the latest cache if no exact match is found
  13. - v1-dependencies-
  14. - run:
  15. name: install dependencies
  16. command: |
  17. python3 -m venv venv
  18. . venv/bin/activate
  19. pip install -r requirements.txt
  20. - save_cache:
  21. paths:
  22. - ./venv
  23. key: v1-dependencies-{{ checksum "requirements.txt" }}
  24. - run:
  25. name: run tests
  26. command: |
  27. . venv/bin/activate
  28. python3 -m unittest discover
  29. - store_artifacts:
  30. path: test-reports
  31. destination: test-reports