Error in unit test fixed