@@ -6,98 +6,100 @@ workflows:
66 jobs :
77 - test-py37
88 - test-py36
9- - test-py27
109 - check
1110
1211jobs :
1312
1413 test-py37 :
1514 docker :
1615 - image : circleci/python:3.7
16+ - image : circleci/postgres:10.5
17+ environment :
18+ POSTGRES_DB : circle_test
19+ POSTGRES_USER : testapp
20+ POSTGRES_PASSWORD : " "
1721 working_directory : ~/rest-auth-toolkit
22+ environment :
23+ DATABASE_URL : postgres://testapp@localhost/circle_test
1824 steps :
1925 - checkout
2026 - restore_cache :
21- key : rest-auth-toolkit-py37-v2
27+ keys :
28+ - rest-auth-toolkit-py37-v7-{{ arch }}-{{ checksum "requirements-test.txt" }}-{{ checksum "demo/requirements.txt" }}
29+ - rest-auth-toolkit-py37-v7-{{ arch }}-{{ checksum "requirements-test.txt" }}
30+ - rest-auth-toolkit-py37-v7-{{ arch }}-
2231 - run :
2332 name : Install CI tools
2433 command : |
2534 python3.7 -m venv venv
2635 venv/bin/pip install tox
2736 - run :
2837 name : Test with Python 3.7
29- command : venv/bin/tox -e py37
38+ command : venv/bin/tox -e py37 -- --junitxml=~/reports/tox/coverage.xml
39+ - run :
40+ name : Check coverage with Python 3.7
41+ command : venv/bin/tox -e coverage
3042 - save_cache :
31- key : rest-auth-toolkit-py37-v2
43+ key : rest-auth-toolkit-py37-v7-{{ arch }}-{{ checksum "requirements-test.txt" }}-{{ checksum "demo/requirements.txt" }}
3244 paths :
3345 - venv
3446 - .tox
47+ - store_test_results :
48+ path : ~/reports
3549
3650 test-py36 :
3751 docker :
3852 - image : circleci/python:3.6
53+ - image : circleci/postgres:10.5
54+ environment :
55+ POSTGRES_DB : circle_test
56+ POSTGRES_USER : testapp
57+ POSTGRES_PASSWORD : " "
3958 working_directory : ~/rest-auth-toolkit
59+ environment :
60+ DATABASE_URL : postgres://testapp@localhost/circle_test
4061 steps :
4162 - checkout
4263 - restore_cache :
43- key : rest-auth-toolkit-py36-v2
64+ keys :
65+ - rest-auth-toolkit-py36-v4-{{ arch }}-{{ checksum "requirements-test.txt" }}-{{ checksum "demo/requirements.txt" }}
66+ - rest-auth-toolkit-py36-v4-{{ arch }}-{{ checksum "requirements-test.txt" }}-{{ checksum "demo/requirements.txt" }}
67+ - rest-auth-toolkit-py36-v4-{{ arch }}-{{ checksum "requirements-test.txt" }}
68+ - rest-auth-toolkit-py36-v4-{{ arch }}-
4469 - run :
4570 name : Install CI tools
4671 command : |
4772 python3.6 -m venv venv
4873 venv/bin/pip install tox
4974 - run :
5075 name : Test with Python 3.6
51- command : venv/bin/tox -e py36
76+ command : venv/bin/tox -e py36 -- --junitxml=~/reports/tox/coverage.xml
5277 - save_cache :
53- key : rest-auth-toolkit-py36-v2
54- paths :
55- - venv
56- - .tox
57-
58- test-py27 :
59- docker :
60- # This image contains Python 3.6 (to install flit) and 2.7 (to run tests)
61- - image : circleci/python:3.6
62- working_directory : ~/rest-auth-toolkit
63- steps :
64- - checkout
65- - restore_cache :
66- key : rest-auth-toolkit-py27-v2
67- - run :
68- name : Install CI tools
69- command : |
70- python3.6 -m venv venv
71- venv/bin/pip install tox
72- - run :
73- name : Test with Python 2.7
74- command : |
75- venv/bin/tox --sdistonly
76- venv/bin/tox -e py27
77- - save_cache :
78- key : rest-auth-toolkit-py27-v2
78+ key : rest-auth-toolkit-py36-v4-{{ arch }}-{{ checksum "requirements-test.txt" }}-{{ checksum "demo/requirements.txt" }}
7979 paths :
8080 - venv
8181 - .tox
82+ - store_test_results :
83+ path : ~/reports
8284
8385 check :
8486 docker :
85- - image : circleci/python:3.6
87+ - image : circleci/python:3.7
8688 working_directory : ~/rest-auth-toolkit
8789 steps :
8890 - checkout
8991 - restore_cache :
90- key : rest-auth-toolkit-check-v3
92+ key : rest-auth-toolkit-check-v6
9193 - run :
9294 name : Install CI tools
9395 command : |
94- python3.6 -m venv venv
96+ python3.7 -m venv venv
9597 venv/bin/pip install tox
9698 - run :
9799 name : Check packaging and dependencies
98100 command : venv/bin/tox -e pkg
99101 - save_cache :
100- key : rest-auth-toolkit-check-v3
102+ key : rest-auth-toolkit-check-v6
101103 paths :
102104 - venv
103105 - .tox
0 commit comments