Fix test compilation issues