]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
Tests: test_volume mock conversion
authorEric Harney <eharney@redhat.com>
Tue, 30 Jun 2015 20:23:51 +0000 (16:23 -0400)
committerEric Harney <eharney@redhat.com>
Tue, 14 Jul 2015 14:10:17 +0000 (10:10 -0400)
commitf9c179c38c83f9d6f4dae47d42328861cef6855e
tree80eb4b69d02ac8a62f079f3f3be1b82dd8f27da9
parent409bc281838a1c1399940a92a72d1192c6cd480d
Tests: test_volume mock conversion

The goal here is to try to drive down complexity in
our tests.  Note that this file is massive and this
will be a gradual effort, not something that will
be completed in one patchset.

osprofiler is mocked out in all unit tests now, so
remove that from here.

Make a first pass at converting these tests over to
mock and strengthen the assertions for calling methods
that were previously mocked with stubs.

Remove a bunch of "fake" methods, using mock instead.

Switch to mock decorators for some tests where it
makes the code easier to follow.  This helps because
it separates test setup from the test itself more
clearly.

Change-Id: Ifdf2980d183cf83c88848a20519403648427a644
cinder/tests/unit/test_volume.py