RETIRED, Fuel CCP - Tests sub-project
Go to file
Dennis Dmitriev a736489db9 Revert only the latest snapshot that matches the test requirements
- add pytest marks 'revert_snapshot' to all required fixtures instead
  of reverting the snapshots inside them
- add get_top_fixtures_marks() that extracts all the marks
  'revert_snapshot' from the test and it's fixtures, order the marks
  in the same way as the fixtures depends on each other,
- in the fixture 'revert_snapshot' try to find the most suitable
  snapshot for reverting, from latest to earliest.
- mark 'revert_snapshot' removed from system tests which use fixtures
  with the same mark (for example, 'k8s_deployed' mark removed from
  system tests where the fixture 'k8scluster' is used as a top fixture)

Change-Id: Iad9e56d96d870aa4204ba23e76a5b4df01d4385b
Co-Authored-By: Dmitry Tyzhnenko <dtyzhnenko@mirantis.com>
2016-11-18 12:38:23 +02:00
doc/source Allow to provide custom oslo config 2016-08-25 09:22:30 +00:00
fuel_ccp_tests Revert only the latest snapshot that matches the test requirements 2016-11-18 12:38:23 +02:00
.gitignore Ignore .ini files with config for snapshot in GIT 2016-09-06 13:36:39 +03:00
.gitreview Prepare fuel-ccp-tests repo 2016-07-11 13:03:27 +02:00
README.rst Add documentation for fuel-ccp-tests 2016-10-19 14:28:07 +02:00
pytest.ini Move tests into a ./tests folder 2016-08-24 18:36:25 +00:00
setup.cfg Add markers to system tests 2016-08-30 17:21:24 +00:00
setup.py Prepare fuel-ccp-tests repo 2016-07-11 13:03:27 +02:00
test-requirements.txt Add ccp show dependency tests 2016-09-07 13:09:32 +03:00
tox.ini Move tests into a ./tests folder 2016-08-24 18:36:25 +00:00

README.rst

Welcome to fuell-ccp-tests documentation!

Structure

` fuel_ccp_tests ├── fixtures ├── helpers ├── logs ├── managers │ └── k8s ├── templates │ ├── k8s_templates │ ├── misc │ └── registry_templates └── tests ├── component │ ├── ccp │ ├── ceph │ ├── k8s │ ├── stacklight │ ├── ui │ └── underlay ├── non-functional ├── system │ ├── pre_commit └── unit`

Fixtures

The directory contains py.test fixtures

Helpers

Contains set of helper methods: checkers, command executors in the container...

Managers

Contains: envmanager - virtual machine layer, snapshot, revert; underlay_ssh_manager - exists for giving possibility manage the environment, existed or created by tests; k8smanager - k8s cluster management.

Templates

Contains .yaml templates with environment configuration(virtual machines, networks, registry)

Tests Overview

The fuel-ccp-test are performed to verify that the completed software (ccp) functions according to the expectations defined by the requirements.

The tests depended on purpose are divided on several categories.

###component/

Consists from several subgroups. The ccp subgroup includes:

  • tests_ccp_cli_messages - checks the output messages depending on the ccp cli command
  • test_ccp_errexit_codes - checks exit codes when commands are failed
  • test_ccp_logging - checking logging on different actions
  • test_dry_run - checking cluster deployment from yaml objects
  • test_reconfig - checking redeployment of one openstack component, and state of the cluster after

###system/

Consists from 2 categories precommit and system. The purpose of the system tests is to maintain the quality of calico, ccp installation, ccp deployment with one/several os, k8s scaling, netchecker. The purpose of precommit is to check cluster components. For the correct precommit execution SERVICE_PATH variable should contains path to fuel-ccp-<some_repo> code with changes. The names of precommit tests were choosing according to the tested components.

Test execution

To execute tests necessary to add value to several variables via export or in the test command. Variables:

  • ENV_NAME - prefix name for the env and VMs
  • IMAGE_PATH - qcow2 image path
  • WORKSPACE - directory path
  • DEPLOY_SCRIPT - cargo path, can be cloned from git.openstack.org/openstack/fuel-ccp-installer
  • SHUTDOWN_ENV_ON_TEARDOWN - live switched ON the env value is (True), switched OFF value if (False)

After exporting execute the command:

py.test -vvv -s -k <test_name> or py.test -vvv -s -m <test_mark>