fix tests using UnsafeIO