Refactor System Tests

Registered by Allele Dev on 2013-08-01

A refactoring of system tests to make them easier to extend and more robust in the face of hidden dependencies.

Blueprint information

Status:
Complete
Approver:
Flavio Percoco
Priority:
High
Drafter:
Allele Dev
Direction:
Needs approval
Assignee:
Flavio Percoco
Definition:
Approved
Series goal:
Accepted for icehouse
Implementation:
Implemented
Milestone target:
milestone icon 2014.1
Started by
Flavio Percoco on 2013-12-13
Completed by
Flavio Percoco on 2013-12-13

Related branches

Sprints

Whiteboard

1. Re-organize test structure , per discussion here https://etherpad.openstack.org/marconi-test-refactoring
2. Remove the numbering (from 000 , 999 etc in test methods) from the system tests. Use http://paste.openstack.org/show/42988/ for test suite setup & teardown
(Use teardown method instead of the http.delete See comments https://review.openstack.org/#/c/40441/1/marconi/tests/system/queue/test_queue.py) (COMPLETE)
3. Update all create_headers to return python dict (COMPLETE)
4. Consider developing a state machine to set up the DB with pre-loaded data, that can be used by the tests.
Gerrit topic: https://review.openstack.org/#q,topic:bp/refactor-system-tests,n,z
5. Using a queue-creating context manager would avoid having to maintain a list of queues to delete at the end of the test. See: https://github.com/cabrera/marconi/blob/fix_system_tests/marconi/tests/system/common/utils.py#L22 (No Longer Applicable, now that we use test level setups)

Addressed by: https://review.openstack.org/39369
    Refactor system tests, update for metadata endpnt

Addressed by: https://review.openstack.org/43388
    Refactor System Tests

Gerrit topic: https://review.openstack.org/#q,topic:refactor-system-tests,n,z

Addressed by: https://review.openstack.org/44475
    Pull actual tests out of marconi/tests

Addressed by: https://review.openstack.org/44476
    Remove util packages

Addressed by: https://review.openstack.org/44477
    Use oslo.config for functional tests

Addressed by: https://review.openstack.org/44723
    Run functional tests under tox

Addressed by: https://review.openstack.org/44749
    Implement embedded marconi-server execution

Addressed by: https://review.openstack.org/45046
    Move Unit tests under a unit package

Addressed by: https://review.openstack.org/45267
    Implement small http client for tests

Addressed by: https://review.openstack.org/45423
    Move functional tests into wsgi/v1

Addressed by: https://review.openstack.org/45877
    Use format instead of % for string formatting

Addressed by: https://review.openstack.org/48057
    Move tests/unit/storage/base under m/tests/storage

Addressed by: https://review.openstack.org/48059
    Move test_default_limits to the new tests location

(?)

Work Items

Dependency tree

* Blueprints in grey have been implemented.

This blueprint contains Public information 
Everyone can see this information.