More improved mocking.  This gets the test suite running again.