Since split between AWS and OS WaitConidtion/Volume resources unit tests
for those resources were not running as they were not discovered.
During this time some changes were merged that actually broke some
tests (mostly the mocking) so this patch fixes those broken tests too.
Some AWS WaitConidtion tests were testing the handle_update method,
which has no sense now as it no longer returns a TaskRunner instance.
These tests were modified to use the general resource.update method.
One test in AWS volumes is modified to use mocked ServerConstraint,
which is added to base TestCase as are stubs for other constraints.
Another test in AWS volumes was using a dumb monkey-patching
instead of proper mock, leading to clashes during concurrent test runs.
Reviewed: https:/ /review. openstack. org/150804 /git.openstack. org/cgit/ openstack/ heat/commit/ ?id=5f3f3794220 53829a406c80b29 1fcbe37c970075
Committed: https:/
Submitter: Jenkins
Branch: master
commit 5f3f37942205382 9a406c80b291fcb e37c970075
Author: Pavlo Shchelokovskyy <email address hidden>
Date: Fri Jan 23 19:03:23 2015 +0200
Enable some unit tests back
Since split between AWS and OS WaitConidtion/ Volume resources unit tests
for those resources were not running as they were not discovered.
During this time some changes were merged that actually broke some
tests (mostly the mocking) so this patch fixes those broken tests too.
Some AWS WaitConidtion tests were testing the handle_update method,
which has no sense now as it no longer returns a TaskRunner instance.
These tests were modified to use the general resource.update method.
One test in AWS volumes is modified to use mocked ServerConstraint,
which is added to base TestCase as are stubs for other constraints.
Another test in AWS volumes was using a dumb monkey-patching
instead of proper mock, leading to clashes during concurrent test runs.
Change-Id: Ie765eab75de835 d5dec94024f1d90 197f1723b4d
Closes-Bug: #1414083