Function dny_run_batch
Source pub fn dny_run_batch<I, T>(
task: I,
task_timeout: Option<Duration>,
only_build: Option<bool>,
on_result: Option<Box<dyn FnMut(String, DnyResult)>>,
) -> Vec<(String, DnyResult)>
Available on crate feature dyntest only.
Expand description
批量运行的便捷入口(不使用依赖预热缓存)。
§Feature Requirement
需要同时启用 "dyntest" 与 "std" 特性。
§Examples
use lib_unknown::dyntest::{DnyTask, dny_run_batch};
let results = dny_run_batch([DnyTask::new("a", "fn main() {}")], None, None, None);
assert_eq!(results.len(), 1);
§Panics
- 任务工程目录创建/文件写入失败时 panic,源于内部
DnyRun 初始化。