forked from openclimatefix/nwp-consumer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtaskfile.yml
47 lines (38 loc) · 1.41 KB
/
taskfile.yml
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
version: '3'
# If you want to run with python from a specific environment,
# set the PYTHON_PREFIX environment variable to
# /path/to/python/dir/
tasks:
install-dependencies:
aliases: ["install"]
desc: "Install application dependencies as defined in pyproject.toml"
cmds:
- ${PYTHON_PREFIX}python -m pip install -q -e .
install-dev-dependencies:
aliases: ["install-dev"]
desc: "Installs development dependencies as defined in pyproject.toml"
cmds:
- ${PYTHON_PREFIX}python -m pip install --upgrade -q pip wheel setuptools
- ${PYTHON_PREFIX}python -m pip install -q -e .[dev]
test-unit:
aliases: ["ut"]
deps: [install-dev-dependencies]
desc: "Run all application unittests"
cmds:
- ${PYTHON_PREFIX}python -m xmlrunner discover -s src/nwp_consumer -p "test_*.py" --output-file ut-report.xml
test-integration:
aliases: ["it"]
deps: [install-dev-dependencies]
desc: "Run all application integration tests"
cmds:
- ${PYTHON_PREFIX}python -m xmlrunner discover -s src/test_integration -p "test_*.py" --output-file it-report.xml
build-wheel:
aliases: ["wheel"]
desc: "Build python wheel"
cmds:
- ${PYTHON_PREFIX}python -m pip wheel . --no-deps --wheel-dir dist
build-container:
aliases: ["cont"]
desc: "Build container"
cmds:
- docker build -f Containerfile . --tag nwp-consumer:local --progress=plain