Esempio n. 1
0
        public void DeleteFilesWithSameContentBytes()
        {
            string folder = @"D:\_Test\sunamo\Helpers\FileSystem\FS\DeleteFilesWithSameContentBytes\";

            var files = FS.GetFiles(folder, "*.txt", System.IO.SearchOption.AllDirectories, new GetFilesArgs {
                _trimA1 = false
            });

            FS.DeleteFilesWithSameContentBytes(files);

            files = FS.GetFiles(folder, "*.txt", System.IO.SearchOption.AllDirectories, new GetFilesArgs {
                _trimA1 = true
            });

            var filesExcepted = CA.ToListString(TestDataTxt.a, TestDataTxt.ab);

            Assert.Equal <string>(filesExcepted, files);
        }