c441608bce
The old was to install oscplugin and then uninstall to test and delete the requirements.txt, that causes problems when requeriments change. This changes it so we install the lib dependencies needed and let tox work as it was planned and install what it needs before running. Change-Id: I42c3e75e7056fba716195a1f95ef3c59c0ca47bf
105 lines
3.5 KiB
YAML
105 lines
3.5 KiB
YAML
# This file is used by the jenkins job
|
|
# read: 'How it works' section at the bottom
|
|
|
|
|
|
### config template ###
|
|
# test_env: # top-level namespace used by khaleesi
|
|
# env_name: # test config
|
|
# Distro-Version: # test configuration for the distro-version
|
|
# | setup: # how the testbed VM needs to be setup
|
|
# | ' repos: # add the following repos
|
|
# | ' - filename: repo-name.repo
|
|
# | ' contents: |
|
|
# | ' [section]
|
|
# | ' contents
|
|
# | ' of
|
|
# | ' Repo
|
|
#
|
|
# | ' install: # install the following rpm and
|
|
# | ' - rpm-abc # ensure latest is installed
|
|
# | ' - rpm-foo
|
|
# | ' - rpm-bar
|
|
#
|
|
# | ' remove: # delete the following rpms
|
|
# | ' - rpm-foo
|
|
# | ' - rpm-bar
|
|
# | ' - rpm-baz
|
|
# | ' pip: # use virtualenv --system-site-packages to
|
|
# | ' overrides: # override system packages
|
|
# | ' - pip-pkg-foo
|
|
# | ' - pip-pkg-foo
|
|
#
|
|
# | run: > # how tests should be run
|
|
# | run_command; another_command;
|
|
# | ./run_tests.sh -N -P # all but last statement should terminated by ;
|
|
#
|
|
# | archive: # what files to archive
|
|
# | - nosetest.xml
|
|
#
|
|
# NOTE: there must be a env_name: called virt: which will be used to run tests
|
|
# in virtualenv when running tests in env_name fails
|
|
|
|
product:
|
|
name: rhos
|
|
repo_type: poodle
|
|
version: 6.0
|
|
config:
|
|
enable_epel: y
|
|
rpmrepo:
|
|
RedHat: http://rhos-release.virt.bos.redhat.com/repos/rhos-release/
|
|
|
|
|
|
python_rdomanager_oscplugin_rpm_deps: [
|
|
gcc, git, python-sphinx, python-tox, python-pip,
|
|
libxml2-devel, libxslt-devel, libffi-devel, openssl-devel,
|
|
]
|
|
|
|
rdomanager_oscplugin_virt_config:
|
|
setup:
|
|
install: "{{python_rdomanager_oscplugin_rpm_deps}}"
|
|
run: >
|
|
sudo rm -Rf .tox || true;
|
|
sudo pip install -U unittest2;
|
|
export NOSE_WITH_XUNIT=1;
|
|
export NOSE_WITH_HTML_OUTPUT=1;
|
|
export NOSE_HTML_OUT_FILE=../logs/nose_results.html;
|
|
export NSS_HASH_ALG_SUPPORT=+MD5;
|
|
export OPENSSL_ENABLE_MD5_VERIFY=1;
|
|
rpm -qa > all-rpms.txt;
|
|
set -o pipefail;
|
|
tox --sitepackages -v -epy27 2>&1 | tee ../logs/venv-testrun.log;
|
|
archive:
|
|
- ../logs/venv-testrun.log
|
|
- tox.ini
|
|
- requirements.txt
|
|
- all-rpms.txt
|
|
|
|
### actual test_config: starts here: used by khaleesi ###
|
|
### NOTE: test_config.virt must be defined ###
|
|
test_config:
|
|
virt:
|
|
Fedora-20: "{{rdomanager_oscplugin_virt_config}}"
|
|
RedHat-7.0: "{{rdomanager_oscplugin_virt_config}}"
|
|
RedHat-7.1: "{{rdomanager_oscplugin_virt_config}}"
|
|
|
|
# How this works!
|
|
# ==============
|
|
# This file is used by khaleesi[1] playbook unit_test.yml[2].
|
|
# - The jenkins job checks out khaleesi, settings and this repo and
|
|
# runs unit_test.yml playbook.
|
|
# - The playbook reads this config file and
|
|
# - adds repos in test_dependencies.rpm.repos
|
|
# - installs all packages in test_dependencies.rpm.install
|
|
# - removes all packages in test_dependencies.rpm.remove
|
|
# - it then runs the test by executing the command specfied in
|
|
# test_env.run NOTE all commands should terminate with a ';'
|
|
# - if tests fail, the same is run in venv with pip packages.
|
|
#
|
|
# PIP overrides
|
|
# -------------
|
|
# When there is no corresponding rpm for a pip package, you can override that
|
|
# particular package using the pip.override section. When you do so, make sure
|
|
# the packaging team is notified about the new requirement.
|
|
#
|
|
# [1] https://github.com/redhat-openstack/khaleesi
|
|
# [2] https://github.com/redhat-openstack/khaleesi/blob/master/playbooks/unit_test.yml |