On Tue, Nov 22, 2011 at 8:31 AM, Soren Hansen <so...@linux2go.dk> wrote: > 2011/11/22 Rohit Karajgi <rohit.kara...@vertex.co.in>: >> Also I really should not feel the need to install a DB on my box to run a >> unit-test suite. None, but the DB API tests should have the need to perform >> any database operations and validations. It slows down the overall execution. >> Such things should be replaced with test doubles. > > I'm making great progress on a fake DB implementation for tests. The > first 1031 tests (out of ~1900) pass now (in 73 seconds). Stay tuned > for progress reports :)
FWIW, I created a fake database store for Glance originally, and indeed the unit tests ran quicker than they do now because we use an in-memory SQLite database in the unit tests. That said, switching from a faked datastore to a real one that actually used the SQLAlchemy code exposed at least 4 bugs that weren't being caught by the fake data store. I understand the desire to speed up the unit test suite, but this desire must always be tempered with a need to test the actual interfaces, not fake ones that mimick an interface but not necessarily duplicate it... Just a thought, -jay _______________________________________________ Mailing list: https://launchpad.net/~openstack Post to : openstack@lists.launchpad.net Unsubscribe : https://launchpad.net/~openstack More help : https://help.launchpad.net/ListHelp