forked from openedx-unsupported/ecommerce
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
83 lines (70 loc) · 2.9 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
[tox]
skipsdist=True
envlist = {py27,py35}-{isort,pycodestyle,pylint,static,tests,extract_translations,dummy_translations,compile_translations, detect_changed_translations,validate_translations}
[testenv]
envdir=
# Use the same environment for all commands running under a specific python version
py27: {toxworkdir}/py27
py35: {toxworkdir}/py35
passenv =
CONN_MAX_AGE
DB_ENGINE
DB_HOST
DB_NAME
DB_PASSWORD
DB_PORT
DB_USER
DISABLE_ACCEPTANCE_TESTS
DISPLAY
DJANGO_SETTINGS_MODULE
ECOMMERCE_CFG
FIREFOX_PROFILE_PATH
JASMINE_HOSTNAME
JASMINE_WEB_DRIVER
SAUCE_API_KEY
SAUCE_USER_NAME
SELENIUM_BROWSER
SELENIUM_FIREFOX_PATH
SELENIUM_HOST
SELENIUM_PLATFORM
SELENIUM_PORT
SELENIUM_VERSION
TRAVIS
setenv =
tests: DJANGO_SETTINGS_MODULE = ecommerce.settings.test
tests: DISABLE_MIGRATIONS=1
BOKCHOY_HEADLESS = true
NODE_BIN = ./node_modules/.bin
PATH=$PATH:$NODE_BIN
SELENIUM_BROWSER=firefox
deps =
-r requirements/dev.txt
whitelist_externals =
/bin/bash
changedir =
dummy_translations,compile_translations,detect_changed_translations,validate_translations: ecommerce
commands =
# Upgrade sqlite to fix crashes during testing.
py27-tests: bash {toxinidir}/scripts/upgrade_pysqlite.sh
static: python manage.py collectstatic --noinput
static: python manage.py compress --force
theme_static: python manage.py update_assets --skip-collect
check_isort: isort --check-only --recursive --diff e2e/ ecommerce/
run_isort: isort --recursive e2e/ ecommerce/
pycodestyle: pycodestyle --config=.pycodestyle ecommerce e2e
pylint: pylint -j 0 --rcfile=pylintrc ecommerce e2e
extract_translations: python manage.py makemessages -l en -v1 -d django --ignore="docs/*" --ignore="src/*" --ignore="i18n/*" --ignore="assets/*" --ignore="node_modules/*" --ignore="ecommerce/static/bower_components/*" --ignore="ecommerce/static/build/*"
extract_translations: python manage.py makemessages -l en -v1 -d djangojs --ignore="docs/*" --ignore="src/*" --ignore="i18n/*" --ignore="assets/*" --ignore="node_modules/*" --ignore="ecommerce/static/bower_components/*" --ignore="ecommerce/static/build/*"
dummy_translations: i18n_tool dummy
compile_translations: python ../manage.py compilemessages
detect_changed_translations: i18n_tool changed
validate_translations: i18n_tool validate -
tests: coverage run --branch --source=ecommerce \
tests: ./manage.py test {posargs:ecommerce} \
tests: --settings=ecommerce.settings.test --with-ignore-docstrings --logging-level=DEBUG
tests: coverage report
serve: python manage.py runserver 0.0.0.0:8002
migrate: python manage.py migrate --noinput
coverage_html: coverage html && open htmlcov/index.html
fast_diff_coverage: coverage xml
fast_diff_coverage: diff-cover coverage.xml --compare-branch=$(DIFF_COVER_BASE_BRANCH)