Added testcase for mocking singleton with newInstanceWithoutConstructor when possible