public void TestSeveralExtractedFilesAreRemovedAfterUse()
 {
     string filename1 = @"\TestFolder\SampleFile1.txt";
     string filename2 = @"\TestFolder\SubFolder\SampleFile2.txt";
     Assert.IsFalse(File.Exists(filename1));
     Assert.IsFalse(File.Exists(filename2));
     using (TemporaryFileHelper helper = new TemporaryFileHelper())
     {
         helper.ExtractFile("SampleFile.txt", filename1);
         helper.ExtractFile("SampleFile.txt", filename2);
         Assert.IsTrue(File.Exists(filename1));
         Assert.IsTrue(File.Exists(filename2));
     }
     Assert.IsFalse(File.Exists(filename1));
     Assert.IsFalse(File.Exists(filename2));
 }
        public void TestSeveralExtractedFilesAreRemovedAfterUse()
        {
            string filename1 = @"\TestFolder\SampleFile1.txt";
            string filename2 = @"\TestFolder\SubFolder\SampleFile2.txt";

            Assert.IsFalse(File.Exists(filename1));
            Assert.IsFalse(File.Exists(filename2));
            using (TemporaryFileHelper helper = new TemporaryFileHelper())
            {
                helper.ExtractFile("SampleFile.txt", filename1);
                helper.ExtractFile("SampleFile.txt", filename2);
                Assert.IsTrue(File.Exists(filename1));
                Assert.IsTrue(File.Exists(filename2));
            }
            Assert.IsFalse(File.Exists(filename1));
            Assert.IsFalse(File.Exists(filename2));
        }
 public void TestExtractedFileIsRemovedAfterUse()
 {
     Assert.IsFalse(File.Exists("SampleFile.txt"));
     using (TemporaryFileHelper helper = new TemporaryFileHelper())
     {
         helper.ExtractFile("SampleFile.txt");
         Assert.IsTrue(File.Exists("SampleFile.txt"));
     }
     Assert.IsFalse(File.Exists("SampleFile.txt"));
 }
 public void TestExtractedFileIsRemovedAfterUse()
 {
     Assert.IsFalse(File.Exists("SampleFile.txt"));
     using (TemporaryFileHelper helper = new TemporaryFileHelper())
     {
         helper.ExtractFile("SampleFile.txt");
         Assert.IsTrue(File.Exists("SampleFile.txt"));
     }
     Assert.IsFalse(File.Exists("SampleFile.txt"));
 }
 public void TestCanExtractToDifferentFolder()
 {
     string filename = @"\TestFolder\SampleFile.txt";
     Assert.IsFalse(File.Exists(filename));
     using (TemporaryFileHelper helper = new TemporaryFileHelper())
     {
         helper.ExtractFile("SampleFile.txt", filename);
         Assert.IsTrue(File.Exists(filename));
     }
     Assert.IsFalse(File.Exists(filename));
 }
        public void TestCanExtractToDifferentFolder()
        {
            string filename = @"\TestFolder\SampleFile.txt";

            Assert.IsFalse(File.Exists(filename));
            using (TemporaryFileHelper helper = new TemporaryFileHelper())
            {
                helper.ExtractFile("SampleFile.txt", filename);
                Assert.IsTrue(File.Exists(filename));
            }
            Assert.IsFalse(File.Exists(filename));
        }