Fix problem in unit test