Fix race condition in the test setup related to wiping mongo.

This was occasionally leading to test failures, since the
database-cleaner wasn't always deleting everything (since a connection
was apparently preventing it from removing collections).

There's still some sporadic test issues present that can be uncovered by
the new "grunt multiTest" task. It seems to be related to custom
configurations not fully taking affect by the time the test runs. Still
need to investigate.