I've created a simple function with a doc test, but when I run
cargo test I get the following output without any tests being run:
Finished dev [unoptimized + debuginfo] target(s) in 1.42s Running target\debug\deps\tool-a3915bdb06e437c0.exe running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
Here is what my doc looks like on the function:
/// Finds any files that are not in the second hashmap that are in the first. /// /// # Arguments /// /// * `hashemap1` - The first hashmap to compare against a second. The keys /// of this hashmap will be compared to the keys of the second hashmap. Any /// keys from this hashmap not in the second will be returns in a vector. /// /// * `hashmap2` - The second hashmap to compare against the first. /// /// # Examples /// /// ``` /// let hashmap1: HashMap<String, String> = HashMap::new(); /// hashmap1.insert("one", "one"); /// hashmap1.insert("two", "two"); /// /// let hashmap2: HashMap<String, String> = HashMap::new(); /// hashmap2.insert("two", "two"); /// hashmap2.insert("three", "three"); /// /// let entries_missing = find_missing_entries(&hashmap1, &hashmap2); /// assert_eq!(entries_missing, vec!["one"]); /// ``` fn find_missing_entries...
IKs it not running because I'm on Windows, or perhaps because I'm not compiling a lib? I'm not sure how to get this to run as a test. I don't see anywhere in the docs that lists requirements for this to work.