1 # Copyright 2019 Canonical Ltd.
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
15 # Tox (http://tox.testrun.org/) is a tool for running tests
16 # in multiple virtualenvs. This configuration file will run the
17 # test suite on all supported python versions. To use it, "pip install tox"
18 # and then run "tox" from this directory.
21 envlist = py3,lint,integration
26 serial
: mark a test that must run by itself
32 # for testing with other python versions
33 commands = py.test --ignore modules/ --ignore tests/charms/ --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
44 # These are needed so executing `charm build` succeeds
58 # default tox env, excludes integration and serial tests
60 pytest
--ignore modules
/ --ignore tests
/charms
/ --tb native
-ra
-v
-n auto
-k 'not integration'
-m 'not serial'
{posargs
}
63 envdir = {toxworkdir}/py3
65 flake8
--ignore E501
,E402
--exclude tests
/charms
/builds
,tests
/charms
/deps
{posargs
} n2vc tests
70 envdir = {toxworkdir}/py3
71 commands = py.test --ignore modules/ --ignore tests/charms/ --tb native -ra -v -s -n 1 -k 'integration' -m 'serial' {posargs}
76 setuptools
-version
-command
77 commands = python3 setup.py --command-packages=stdeb.command bdist_deb