Function spielrs_diff::dir_diff[][src]

pub async fn dir_diff(dir_diff_options: DirDiff) -> bool
Expand description

Compare two directories and return true if both are different You can exclude directories or files in the comparation only from the root path of both or recursively


use spielrs_diff::{dir_diff, diff::DirDiff};

async fn should_return_true_if_both_dir_tree_are_different() {
   let diff = dir_diff(DirDiff {
       dir: "./mocks/dir_one".to_string(),
       dir_comp: "./mocks/dir_five".to_string(),
       excluding: Some(vec!["purpose".to_string()]),
       recursive_excluding: true,

   assert_eq!(diff, true);