Fix unit tests