Fixed small bug in unit test