Fix unit test regressions