mirror of
https://github.com/rust-lang-nursery/rust-cookbook
synced 2024-11-22 03:23:05 +00:00
Implemented test automation
This commit is contained in:
parent
02a3497a35
commit
aa2edabe59
1 changed files with 11 additions and 1 deletions
12
build.rs
12
build.rs
|
@ -1,5 +1,15 @@
|
||||||
extern crate skeptic;
|
extern crate skeptic;
|
||||||
|
|
||||||
|
use std::fs;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
skeptic::generate_doc_tests(&["README.md"]);
|
let paths = fs::read_dir("./pages/").unwrap();
|
||||||
|
|
||||||
|
for path in paths {
|
||||||
|
let p = path.unwrap().path();
|
||||||
|
let s = p.to_str().unwrap();
|
||||||
|
if s.contains(".md") {
|
||||||
|
skeptic::generate_doc_tests(&[s])
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue