Reorganize fuel-qa helpers with movement to core and cover it by unit-tests

Registered by Aleksei Stepanov

Move all not test-driver related helpers to core and cover it by unittests.

Blueprint information

Status:
Not started
Approver:
Nastya Urlapova
Priority:
Undefined
Drafter:
Aleksei Stepanov
Direction:
Needs approval
Assignee:
Aleksei Stepanov
Definition:
Discussion
Series goal:
None
Implementation:
Unknown
Milestone target:
None

Related branches

Sprints

Whiteboard

Current problem: we have a lot of helpers and we could not guarantee, that them could correctly interact due to it's not covered by unit tests and custom tests is not cover whole API.
Solution: use unit tests.

Additional problem: Currently we have multiple places, where helpers are stored and called from. As result, sometimes we could have up to 90% LOC intersects between helpers.
Solution: create dedicated place for shared code. I propose package, named 'core' in the root of repository. Also this way allow to fix coverage level problem: check by unit tests only shared helpers package and set minimal coverage level on package implementation start.
Movement of helpers: move 1 helper per patch, in this pach ALL requests to this method should be changed. On the old place should be created temporary "proxy" method with deprecation warning and announcement time, when it will be deleted (not less, than 15 days after deprecation). After timeout, this proxy methods should be deleted.

Additional problem: pytest integration was started on master branch. Conflicts is possible.
Solution: pending. Expect, that unit tests should present under core too due to it covers only core methods.

Due to active work on 2 branges for now: master and stable/mitaka, this activiti should present on both branches

Gerrit topic: https://review.openstack.org/#q,topic:bp/fuel-qa-self-test,n,z

Addressed by: https://review.openstack.org/360375
    Create initial unittest infrastructure

Gerrit topic: https://review.openstack.org/#q,topic:bp/fuel-qa-join-helpers,n,z

Addressed by: https://review.openstack.org/360881
    Create initial infrastructure for fuel-qa refactoring: .core package

Gerrit topic: https://review.openstack.org/#q,topic:cpllector_client,n,z

Addressed by: https://review.openstack.org/360983
    setup_teardown: move to core anc cover by unit tests

Addressed by: https://review.openstack.org/361026
    setup_teardown: move to core anc cover by unit tests

Gerrit topic: https://review.openstack.org/#q,topic:363571,n,z

Addressed by: https://review.openstack.org/363571
    Rework logger

Addressed by: https://review.openstack.org/364069
    Rework logger

Addressed by: https://review.openstack.org/364750
    Move QuietLogger and logwrap to core

Addressed by: https://review.openstack.org/364791
    Initialize NailgunClient with session only

Addressed by: https://review.openstack.org/364827
    Move QuietLogger and logwrap to core

Addressed by: https://review.openstack.org/364828
    Initialize NailgunClient with session only

Addressed by: https://review.openstack.org/365604
    Start NailgunClient implementation for Mitaka and Newton in core

Addressed by: https://review.openstack.org/365857
    Start NailgunClient implementation for Mitaka and Newton in core

(?)

Work Items

Work items:
Implement start package structure: DONE
Implement test start mechanism: DONE
Add required venv to the tox.ini (cover): DONE
(Optional) add unittest requirements to the test requirements: TODO
Start movement: INPROGRESS

This blueprint contains Public information 
Everyone can see this information.

Subscribers

No subscribers.