update/software/tox.ini
Bin Qian ebe177d918 USM deploy state
This change introduced state machines for release state, deploy state
and deploy host state.

This change removed the direct reference to the software metadata from
software-controller and other modules. Replaced with encapuslated
release_data module.

Also include changes:
1. removed required parameter for software deploy activate and software
deploy complete RestAPI.
2. ensure reload metadata for each request
3. added feed_repo and commit-id to the deploy entity, to be
   subsequently passed to deploy operations.
4. fix issues

TCs:
    passed: software upload major and patching releases
    passed: software deploy start major and patching releases
    passed: software deploy host (mock) major and patching release
    passed: software activate major and patching release
    passed: software complete major release and patching release
    passed: redeploy host after host deploy failed both major and
patching release

Story: 2010676
Task: 49849

Change-Id: I4b1894560eccb8ef4f613633a73bf3887b2b93fb
Signed-off-by: Bin Qian <bin.qian@windriver.com>
2024-04-17 16:40:07 +00:00

87 lines
1.9 KiB
INI

#
# Copyright (c) 2023 Wind River Systems, Inc.
#
# SPDX-License-Identifier: Apache-2.0
#
[tox]
envlist = pep8,py39,pylint
minversion = 2.3.2
skipsdist = True
stxdir = {toxinidir}/../..
[testenv]
allowlist_externals = find
sh
basepython = python3
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
-e{[tox]stxdir}/fault/fm-api/source
-e{[tox]stxdir}/config/tsconfig/tsconfig
install_command = pip install -v -v -v \
-c {env:UPPER_CONSTRAINTS_FILE:https://opendev.org/starlingx/root/raw/branch/master/build-tools/requirements/debian/upper-constraints.txt} \
{opts} {packages}
passenv =
XDG_CACHE_HOME
setenv = VIRTUAL_ENV={envdir}
LANG=en_US.UTF-8
LANGUAGE=en_US:en
LC_ALL=C
OS_STDERR_CAPTURE=1
OS_STDOUT_CAPTURE=1
OS_TEST_TIMEOUT=60
PYTHONDONTWRITEBYTECODE=True
PYTHONHASHSEED=0
sitepackages = False
usedevelop = true
[bandit]
exclude = tests
skips =
[testenv:bandit]
commands = bandit --ini tox.ini -n 5 -r software
[testenv:cover]
setenv =
{[testenv]setenv}
PYTHON=coverage run --parallel-mode
commands =
coverage erase
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
coverage report
[flake8]
# H106: Don't put vim configuration in source files (off by default).
# H203: Use assertIs(Not)None to check for None (off by default).
enable-extensions = H106,H203
exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,release-tag-*
max-line-length = 120
show-source = True
ignore = E402,H306,H404,H405,W504,E501,H105
[testenv:flake8]
commands = flake8 {posargs}
[testenv:pep8]
commands = flake8 {posargs}
[testenv:py39]
basepython = python3.9
commands =
stestr run {posargs}
stestr slowest
[testenv:pylint]
commands = pylint software --rcfile=./pylint.rc
[stestr]
test_path=./software/tests
top_dir=./
group_regex=([^\.]*\.)*