File: tox.ini

package info (click to toggle)
plover 5.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 14,356 kB
  • sloc: python: 21,589; sh: 682; ansic: 25; makefile: 11
file content (108 lines) | stat: -rw-r--r-- 2,485 bytes parent folder | download
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
[tox]
minversion = 4.0
envlist = test

[helpers]
functions =
	bash --noprofile --norc -eo pipefail -c ' \
		. ./plover_build_utils/functions.sh; \
		python=python; \
		"$@"'
# If `-e` is present in the arguments, call pip directly,
# otherwise, use `plover_build_utils.install_wheels`.
install_command =
	{envpython} -c 'import subprocess, sys; \
		from plover_build_utils.install_wheels import WHEELS_CACHE, install_wheels; \
		args = sys.argv[1:]; \
		subprocess.check_call([sys.executable, "-m", "pip", \
				       "install", "--no-build-isolation", \
				       "-f", WHEELS_CACHE] + args) \
		if "-e" in args else \
		install_wheels(args)'

# Default, Python 3 based, environment.
[testenv]
envdir = {toxworkdir}/dev
extras =
	gui_qt
	log
deps =
	-c	reqs/constraints.txt
	-r	reqs/bootstrap.txt
	-r	reqs/build.txt
	-r	reqs/ci.txt
	-r	reqs/dist.txt
	-r	reqs/dist_extra_gui_qt.txt
	-r	reqs/dist_extra_log.txt
	-r	reqs/packaging.txt
	-r	reqs/release.txt
	-r	reqs/setup.txt
	-r	reqs/test.txt
install_command = {[helpers]install_command} {packages}
list_dependencies_command = {envpython} -m pip freeze --all
allowlist_externals = bash
passenv =
	MACOSX_DEPLOYMENT_TARGET
setenv =
	SSL_CERT_FILE={envsitepackagesdir}/certifi/cacert.pem

# Lightweight tests only environments.
[testenv:py3{,6,7,8,9,10,11,12,13}]
description = run tests using {envname}
base_python = {envname}
envdir = {toxworkdir}/{envname}
extras =
	gui_qt
deps =
	-c	reqs/constraints.txt
	-r	reqs/bootstrap.txt
	-r	reqs/dist.txt
	-r	reqs/setup.txt
	-r	reqs/test.txt
setenv =
	{[testenv:test]setenv}
commands =
	{envpython} -m pytest {posargs}

[testenv:launch]
description = launch plover
usedevelop = true
passenv =
	{[testenv]passenv}
	DISPLAY
	XDG_RUNTIME_DIR
commands =
	{envpython} setup.py launch -- {posargs}

[testenv:packaging_checks]
description = packaging sanity checks
setenv =
	PIP_FIND_LINKS={toxinidir}/.cache/wheels
commands =
	{[helpers]functions} -- packaging_checks {posargs}

[testenv:plugins_install]
description = install specified plugins
usedevelop = true
commands =
	{[helpers]install_command} {posargs}

[testenv:release_{prepare,finalize}]
description = prepare/finalize a release
passenv = *
commands =
	{[helpers]functions} -- {envname} {posargs}

[testenv:setup]
description = run a `setup.py` command
commands =
	{envpython} setup.py {posargs}

[testenv:test]
description = run tests
setenv =
	QT_QPA_PLATFORM=offscreen
commands =
	{envpython} -m pytest {posargs}

# vim: ft=cfg list