diff options
author | Kenneth Hsu <kennethhsu@gmail.com> | 2020-09-27 21:07:52 +0300 |
---|---|---|
committer | Kenneth Hsu <kennethhsu@gmail.com> | 2020-09-28 00:06:03 +0300 |
commit | d5b6386cfef65b26d30ef637396a4ed15dc379ea (patch) | |
tree | 612e433d588facb37167d53c3034ecf5f2ae8504 /Duplicati | |
parent | dc0c6025ef9b4104e42782c345d3be07ae2b7e9a (diff) |
Use helper method to compare contents of directories.
Diffstat (limited to 'Duplicati')
-rw-r--r-- | Duplicati/UnitTest/RecoveryToolTests.cs | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/Duplicati/UnitTest/RecoveryToolTests.cs b/Duplicati/UnitTest/RecoveryToolTests.cs index dfc6cbd34..b81d7b25a 100644 --- a/Duplicati/UnitTest/RecoveryToolTests.cs +++ b/Duplicati/UnitTest/RecoveryToolTests.cs @@ -90,17 +90,7 @@ namespace Duplicati.UnitTest // last folder in the path. string baseFolder = Path.GetFileName(this.DATAFOLDER); - foreach (string filepath in Directory.EnumerateFiles(this.DATAFOLDER)) - { - string filename = Path.GetFileName(filepath); - TestUtils.AssertFilesAreEqual(filepath, Path.Combine(restoreFolder, baseFolder, filename ?? String.Empty), false, filename); - } - - foreach (string filepath in Directory.EnumerateFiles(subdirectoryPath)) - { - string filename = Path.GetFileName(filepath); - TestUtils.AssertFilesAreEqual(filepath, Path.Combine(restoreFolder, baseFolder, subdirectoryName, filename ?? String.Empty), false, filename); - } + TestUtils.AssertDirectoryTreesAreEquivalent(this.DATAFOLDER, Path.Combine(restoreFolder, baseFolder), false, "Verifying restore using RecoveryTool."); } } }
\ No newline at end of file |