aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2018-04-07 23:23:10 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2018-04-08 00:52:51 +0200
commit1d72880c097ea8259ce9cc63cfe55e6cc7516bd2 (patch)
tree44d7f9089468f35277bb8d0257da0f3a3bb88448 /Makefile
parente7d7c0e5645da35adcbfec9e51deb68f012c422f (diff)
downloadTrader-1d72880c097ea8259ce9cc63cfe55e6cc7516bd2.tar.gz
Trader-1d72880c097ea8259ce9cc63cfe55e6cc7516bd2.tar.zst
Trader-1d72880c097ea8259ce9cc63cfe55e6cc7516bd2.zip
Add acceptance tests
Fixes https://git.immae.eu/mantisbt/view.php?id=42 (new scenario files still need to be added to improve coverage)
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 3 insertions, 12 deletions
diff --git a/Makefile b/Makefile
index 7660895..e304426 100644
--- a/Makefile
+++ b/Makefile
@@ -15,7 +15,7 @@ release_version = $(shell git describe --tags --always)
15release_file = trader_$(release_version).tar.gz 15release_file = trader_$(release_version).tar.gz
16folder = ~/.no_backup/projets/git.immae.eu/releases/cryptoportfolio/trader 16folder = ~/.no_backup/projets/git.immae.eu/releases/cryptoportfolio/trader
17 17
18coverage_omit = "tests/*.py,test.py" 18coverage_omit = "tests/*.py,test.py,test_acceptance.py"
19 19
20build_release: 20build_release:
21 git archive HEAD -o $(release_file) 21 git archive HEAD -o $(release_file)
@@ -27,7 +27,7 @@ build_release:
27 @echo "=================================" 27 @echo "================================="
28 28
29test_coverage_unit: 29test_coverage_unit:
30 coverage run --source=. --omit="$(coverage_omit)" test.py --onlyunit 30 coverage run --source=. --omit="$(coverage_omit)" test.py
31 coverage report -m 31 coverage report -m
32 32
33test_coverage_unit_html: test_coverage_unit 33test_coverage_unit_html: test_coverage_unit
@@ -36,19 +36,10 @@ test_coverage_unit_html: test_coverage_unit
36 @echo "coverage in https://www.immae.eu/htmlcov" 36 @echo "coverage in https://www.immae.eu/htmlcov"
37 37
38test_coverage_acceptance: 38test_coverage_acceptance:
39 coverage run --source=. --omit="$(coverage_omit)" test.py --onlyacceptance 39 coverage run --source=. --omit="$(coverage_omit)" test_acceptance.py
40 coverage report -m 40 coverage report -m
41 41
42test_coverage_acceptance_html: test_coverage_acceptance 42test_coverage_acceptance_html: test_coverage_acceptance
43 coverage html 43 coverage html
44 rm ~/hosts/www.immae.eu/htmlcov -rf && cp -r htmlcov ~/hosts/www.immae.eu 44 rm ~/hosts/www.immae.eu/htmlcov -rf && cp -r htmlcov ~/hosts/www.immae.eu
45 @echo "coverage in https://www.immae.eu/htmlcov" 45 @echo "coverage in https://www.immae.eu/htmlcov"
46
47test_coverage_all:
48 coverage run --source=. --omit="$(coverage_omit)" test.py
49 coverage report -m
50
51test_coverage_all_html: test_coverage_all
52 coverage html
53 rm ~/hosts/www.immae.eu/htmlcov -rf && cp -r htmlcov ~/hosts/www.immae.eu
54 @echo "coverage in https://www.immae.eu/htmlcov"