Function snapbox::assert_subset_matches
source ยท pub fn assert_subset_matches(
pattern_root: impl Into<PathBuf>,
actual_root: impl Into<PathBuf>,
)
Available on crate feature
dir
only.Expand description
Check if a path matches the pattern of another path, recursively
Pattern syntax:
...
is a line-wildcard when on a line by itself[..]
is a character-wildcard when inside a line[EXE]
matches.exe
on Windows
Normalization:
- Newlines
\
to/
let output_root = "...";
let expected_root = "tests/snapshots/output.txt";
snapbox::assert_subset_matches(expected_root, output_root);