Beispiel #1
0
        public void ExploreZip()
        {
            var config     = System.IO.Path.Combine(_testDirectory, "configuration_zip.xml");
            var outputFile = System.IO.Path.Combine(_outputDirectory, "ExploreZip.zip");
            var targets    = CKPackAliases.GetTargetsFromConfigurationFile(_context, config);

            CKPackAliases.Pack(_context, targets, outputFile, true);

            CheckZipContent(outputFile, new[] {
                @"Sub1\ZipFileSub1.txt",
                @"Sub1\Sub2\ZipFileSub2.txt",
                @"Sub1\Sub2\ZipFileSub2-2.txt"
            });
        }
Beispiel #2
0
        public void PackFromConfigurationFile()
        {
            var config     = System.IO.Path.Combine(_testDirectory, "configuration.xml");
            var outputFile = System.IO.Path.Combine(_outputDirectory, "PackFromConfigurationFile.zip");
            var targets    = CKPackAliases.GetTargetsFromConfigurationFile(_context, config);

            CKPackAliases.Pack(_context, targets, outputFile);

            Assert.IsTrue(File.Exists(outputFile), "Created zip - Output file not found");

            CheckZipContent(outputFile, new[] {
                "RootFile.txt",
                @"Target1\File1.txt",
                @"Target1\File2.txt",
                @"Target1\ZipContent.zip",
                @"Target3\File5.txt"
            });
        }