The DatabaseFixture was previously just ensuring that tests which used
it had a clean database when they started. It did not ensure there was
no working database around when it wasn't being used, so tests which
leaked into the database might pass even if they were listed as a
NoDBTest, because there was an in memory test db from a prior run.
This adds a cleanup path to the fixture which blows away the db at the
end of the test (which itself is tested). There were 46 tests which
failed when we got this isolation correct, and this changes all those
test classes containing those tests to require a db. Many of these
could have narrower fixes, but this returns us to an isolated state.
This patch changes, where it's posible, tests-package
to using test.NoDBTestCase saving test case running time.
Co-Authored-By: yuntongjin <email@example.com>
As part of the split of functional and unit tests we need to isolate
the unit tests into a separate directory for having multiple test
targets in a sane way.
Part of bp:functional-tests-for-nova