feature: Add ZUUL JOBs

1. Add `skyline-tox-functional-py38` job to execute unit tests
2. Add `skyline-tox-lint-py38` job to execute code static analysis

Change-Id: I6ee8e89e72b3769a2803f8dc2a7b7a434f16e16f
This commit is contained in:
shaleijie 2021-08-24 10:48:38 +08:00 committed by leijiesha
parent bea439480a
commit 08126209de
4 changed files with 64 additions and 2 deletions

View File

@ -1,3 +1,27 @@
- job:
name: skyline-tox-functional-py38
parent: openstack-tox-functional-py38
description: |
Skyline py38 functional tests
vars:
python_version: 3.8
tox_envlist: functional-py38
- job:
name: skyline-tox-lint-py38
parent: openstack-tox-functional-py38
description: |
Skyline code static analysis
vars:
python_version: 3.8
tox_envlist: lint
- project:
templates:
- noop-jobs
check:
jobs:
- skyline-tox-functional-py38
- skyline-tox-lint-py38
gate:
jobs:
- skyline-tox-functional-py38
- skyline-tox-lint-py38

View File

@ -1,5 +1,10 @@
PYTHON ?= python3
IGNORE_JS ?= false
ifeq ($(IGNORE_JS), $(filter $(IGNORE_JS), true True TRUE))
LIBS := $(shell \ls -I skyline-console libs)
else
LIBS := $(shell \ls libs)
endif
LIB_PATHS := $(addprefix libs/,$(LIBS))
ROOT_DIR ?= $(shell git rev-parse --show-toplevel)

4
bindep.txt Normal file
View File

@ -0,0 +1,4 @@
# This is a cross-platform list tracking distribution packages needed by tests;
# see http://docs.openstack.org/infra/bindep/ for additional information.
make

29
tox.ini Normal file
View File

@ -0,0 +1,29 @@
[tox]
minversion = 3.18.0
# python runtimes: https://governance.openstack.org/tc/reference/runtimes/ussuri.html
envlist = functional-py38,lint
skipsdist=true
# this allows tox to infer the base python from the environment name
# and override any basepython configured in this file
ignore_basepython_conflict=true
isolated_build=true
[testenv]
# Set default python version
basepython = python3
whitelist_externals =
make
setenv =
IGNORE_JS = True
passenv = IGNORE_JS
deps = poetry != 1.1.8
[testenv:functional-py38]
commands =
make install
make test
[testenv:lint]
commands =
make install
make lint