我需要测试以下代码:
try{
while((testBean = csvReader.read(TestBean.class,headers,getCellProcessors()))!=null){
System.out.println("no excpetion");
i=5;
}
}catch(SuperCsvException csvExc){
System.out.println("superCSV excpetion");
i=0;
}catch(Exception ex){
System.out.println("excpetion");
i=0;
}
Run Code Online (Sandbox Code Playgroud)
如何测试是否SuperCsvException被抛出和被捕获。
我尝试使用curl 在 RHEL 6.10 上安装 rust 1.48 并收到以下错误
info: downloading installer
Cannot execute /tmp/tmp.ShsTMGuMqK/rustup-init (likely because of mounting /tmp as noexec).
Please copy the file to a location where you can execute binaries and run ./rustup-init.
Run Code Online (Sandbox Code Playgroud)
这是我安装 Rust 的命令
curl --insecure -sSf -o $HOME/rust/rustup-init https://sh.rustup.rs
chmod +x $HOME/rust/rustup-init
./$HOME/rust/rustup-init -s -y --default-toolchain 1.48
Run Code Online (Sandbox Code Playgroud)
我发现这个https://github.com/rust-lang/rust/issues/39771但它不起作用。我的 $HOME 目录也有写权限