-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
87 lines (79 loc) · 2.46 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
84
85
86
87
[project]
; docker_registry = 172.16.30.170:50000
; icon = {toxinidir}{/}logo.ico
; --------------------------------------------------
[tox]
skipsdist = 1 # does not generate a package, defaults to false
isolated_build = True
envlist =
format
coverage
; --------------------------------------------------
[testenv:format]
description = lint and format code with yapf, isort and flake8
skip_install = true
deps =
toml==0.10.2
yapf==0.40.2
isort==5.13.2
flake8==7.0.0
Flake8-pyproject==1.2.3
commands =
yapf {toxinidir}{/}build_scripts {toxinidir}{/}tests {toxinidir}{/}src -irp
isort {toxinidir}{/}build_scripts {toxinidir}{/}tests {toxinidir}{/}src
flake8 {toxinidir}{/}build_scripts {toxinidir}{/}tests {toxinidir}{/}src
; --------------------------------------------------
[testenv:coverage]
description = execute unittests and generate coverage report
# changedir = {envtmpdir}
deps =
-r requirements.txt
coverage[toml]==7.4.1
pytest==8.0.1
commands =
coverage run --source={toxinidir}{/}src --branch -m pytest {toxinidir}
coverage html
; --------------------------------------------------
[testenv:build_consumer_exe]
description = create an .exe from /src/consumer/main.py using pyarmor
deps =
-r requirements.txt
pyinstaller-versionfile==2.1.1
pyinstaller==6.4.0
pyarmor==7.7.4
{[testenv:format]deps}
{[testenv:coverage]deps}
commands =
{[testenv:format]commands}
{[testenv:coverage]commands}
python "./build_scripts/consumer.py"
; --------------------------------------------------
[testenv:build_producer_exe]
description = create an .exe from /src/producer/main.py using pyarmor
deps =
-r requirements.txt
pyinstaller-versionfile==2.1.1
pyinstaller==6.4.0
pyarmor==7.7.4
{[testenv:format]deps}
{[testenv:coverage]deps}
commands =
{[testenv:format]commands}
{[testenv:coverage]commands}
python "./build_scripts/producer.py"
; --------------------------------------------------
[testenv:build_producer_consumer_exe]
description = create an .exe from producer and consumer files using pyarmor
deps =
-r requirements.txt
pyinstaller-versionfile==2.1.1
pyinstaller==6.4.0
pyarmor==7.7.4
{[testenv:format]deps}
{[testenv:coverage]deps}
commands =
{[testenv:format]commands}
{[testenv:coverage]commands}
python "./build_scripts/producer.py"
python "./build_scripts/consumer.py"
; --------------------------------------------------