public static void delete(File fileOrDir) throws IOException {
        if (fileOrDir == null) {
            return;
        }
        
        if (fileOrDir.isDirectory()) {
            cleanDirectory(fileOrDir);
        } else {
            if (fileOrDir.exists()) {
                boolean isDeleteOk = fileOrDir.delete();
                if (!isDeleteOk) {
                    throw new IOException("delete fail");
                }
            }
        }
    }
@Test
    void testDeleteForNullFile() throws IOException {
        IoUtils.delete(null);
    }