Remove the use of resource autodeletion in unit tests

Registered by Maru Newby on 2014-07-11

The Neutron unit tests currently decorate resource creation methods with contextlib.contextmanager to allow resources to be automatically deleted when they are no longer needed. This strategy is a legacy of a time when this explicit cleanup was required to ensure isolation between tests, but is now unnecessary since db state is automatically thrown away after each test. Given that autodeletion has an execution and code maintenance penalty, its removal is adviseable.

Blueprint information

Status:
Complete
Approver:
Kyle Mestery
Priority:
Medium
Drafter:
Maru Newby
Direction:
Approved
Assignee:
Kevin Benton
Definition:
Approved
Series goal:
Accepted for juno
Implementation:
Implemented
Milestone target:
milestone icon 2014.2
Started by
Kevin Benton on 2014-08-12
Completed by
Kyle Mestery on 2014-09-12

Related branches

Sprints

Whiteboard

September-5 (rkukura): This BP sounds to me more like a bug fix that should not require an FFE to merge after FF.

September-2 (mestery): Per discussion with Maru, this won't make Juno-3 and will need an FFE to make Juno RC1.

16-July (mestery): Approved for Juno, marking as Juno-3.

Gerrit topic: https://review.openstack.org/#q,topic:bp/remove-unit-test-autodeletion,n,z

Addressed by: https://review.openstack.org/106277 (Merged)
    Add spec for removal of autodeletion in tests

Code here:
https://review.openstack.org/#/c/102465/ (Merged)

Addressed by: https://review.openstack.org/102465 (Merged)
    UTs: Disable auto deletion of ports/subnets/nets

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.

Subscribers

No subscribers.