Full compile fix for -unittest.