Fixed test: mock object did not return the expected object