Esempio n. 1
0
        public Task TestSideBySideWithGitRepo()
        {
            return(ApplicationManager.RunAsync("TestSimpleZipDeployment", async appManager =>
            {
                using (var repo = Git.Init(Path.Combine(Path.GetTempPath(), Path.GetRandomFileName())))
                {
                    // First deploy zip
                    var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    var response = await DeployZip(appManager, files, new ZipDeployMetadata());
                    response.EnsureSuccessStatusCode();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");

                    await appManager.SettingsManager.SetValue(SettingsKeys.ScmType, "LocalGit");

                    // Push-deploy git repo
                    var gitFilePath = Path.Combine(repo.PhysicalPath, Path.GetRandomFileName());
                    File.WriteAllText(gitFilePath, Guid.NewGuid().ToString("N"));
                    Git.Commit(repo.PhysicalPath, "Initial commit");
                    var gitResult = appManager.GitDeploy(repo.PhysicalPath);
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, Directory.GetFiles(repo.PhysicalPath).Select(f => Path.GetFileName(f)).ToArray(), "site/wwwroot");

                    // Deploy new zip
                    var files2 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    var response2 = await DeployZip(appManager, files2, new ZipDeployMetadata());
                    response2.EnsureSuccessStatusCode();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files2.Select(f => f.Filename).ToArray(), "site/wwwroot");

                    // Redeploy git deployment
                    var id = Git.Id(repo.PhysicalPath);
                    var response3 = await appManager.DeploymentManager.DeployAsync(id);
                    response3.EnsureSuccessStatusCode();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, Directory.GetFiles(repo.PhysicalPath).Select(f => Path.GetFileName(f)).ToArray(), "site/wwwroot");
                }
            }));
        }
Esempio n. 2
0
        public Task TestManifestPropagatedCorrectly()
        {
            return ApplicationManager.RunAsync("TestManifestPropagatedCorrectly", async appManager =>
            {
                // We run this test in 3 steps: Zipdeploy, then OneDeploy, and then ZipDeploy again
                // And then we check if the second ZipDeploy works as expected

                // STEP 1a: Upload a zip using ZipDeploy
                var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                await DeployZippedArtifact(appManager, appManager.ZipDeploymentManager, files1, type: "", path: "", isAsync: false);

                // STEP 1b: Validate the ZipDeploy result
                var expectedFiles1 = files1.Select(f => f.Filename).ToList();
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot");

                // STEP 2a: Upload a text file using OneDeploy
                await DeployNonZippedArtifact(appManager, "static", "site/wwwroot/staticfiletest.txt", isAsync: false);

                // STEP 2b: Validate the OneDeploy result
                expectedFiles1.Add("staticfiletest.txt");
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot");

                // STEP 3a: Upload a zip using ZipDeploy
                var files2 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                await DeployZippedArtifact(appManager, appManager.ZipDeploymentManager, files2, type: "", path: "", isAsync: false);

                // STEP 3b: Validate the ZipDeploy result
                // Specifically, we want to make sure that the files deployed by the first 
                // ZipDeploy are wiped out but the file deployed by OneDeploy is left untouched
                // If this happens, we can assume that OneDeploy does not interfere with ZipDeploy
                var expectedFiles2 = files2.Select(f => f.Filename).ToList();
                expectedFiles2.Add("staticfiletest.txt");
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles2.ToArray(), "site/wwwroot");
            });
        }
Esempio n. 3
0
        public Task EnsureExpectedKudusyncBehavior()
        {
            return(ApplicationManager.RunAsync("EnsureExpectedKudusyncBehavior", async appManager =>
            {
                var origTime = DateTime.Now;
                var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                foreach (var file in files)
                {
                    file.ModifiedTime = origTime;
                }

                var response = await DeployZip(appManager, files, new ZipDeployMetadata());
                response.EnsureSuccessStatusCode();
                await AssertSuccessfulDeploymentByContent(appManager, files);

                // Deploy a new zip with some new files, some modified files, and some old files
                var newFiles = DeploymentTestHelper.CreateRandomFilesForZip(3);
                var oldfile = files[0];
                var modifiedFile = new TestFile {
                    Filename = files[1].Filename, Content = "UPDATED", ModifiedTime = DateTime.Now
                };
                var files2 = newFiles.Concat(new[] { oldfile, modifiedFile }).ToArray();

                var response2 = await DeployZip(appManager, files2, new ZipDeployMetadata());
                response2.EnsureSuccessStatusCode();
                await AssertSuccessfulDeploymentByContent(appManager, files2);

                // Would need to check the trace log to ensure that the old file wasn't actually copied, but preserved.
            }));
        }
Esempio n. 4
0
        public Task EnsureConflictResultOnSimultaneousSyncRequest()
        {
            return(ApplicationManager.RunAsync("EnsureConflictResultOnSimultaneousSyncRequest", async appManager =>
            {
                // Big enough to run for a few seconds
                var files = DeploymentTestHelper.CreateRandomFilesForZip(1000);
                var response = await DeployZip(appManager, files, new ZipDeployMetadata {
                    IsAsync = true
                });
                response.EnsureSuccessStatusCode();

                // Immediately try another deployment
                var response2 = await DeployZip(appManager, new TestFile[0], new ZipDeployMetadata());

                Assert.Equal(HttpStatusCode.Conflict, response2.StatusCode);

                DeployResult result;
                do
                {
                    result = await appManager.DeploymentManager.GetResultAsync("latest");
                    Assert.Equal(GetZipDeployer(), result.Deployer);
                    await Task.Delay(TimeSpan.FromSeconds(2));
                } while (!new[] { DeployStatus.Failed, DeployStatus.Success }.Contains(result.Status));

                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");
            }));
        }
Esempio n. 5
0
        public Task TestLegacyWarDeployment(bool isAsync)
        {
            return(ApplicationManager.RunAsync("TestLegacyWarDeployment", async appManager =>
            {
                var initialFileName = DeploymentTestHelper.DeployRandomFilesEverywhere(appManager);

                // Incremental deployment - NOT supported, will be ignored
                {
                    var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files1, "war", "webapps/ROOT", isAsync, isClean: false);

                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, new string[] { initialFileName, "ROOT", "ROOT2" }, "site/wwwroot/webapps");
                    var expectedFiles1 = files1.Select(file => file.Filename).ToList();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot/webapps/ROOT");
                }

                // Default deployment - clean
                {
                    var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files1, "war", "webapps/ROOT2", isAsync);

                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, new string[] { initialFileName, "ROOT", "ROOT2" }, "site/wwwroot/webapps");
                    var expectedFiles1 = files1.Select(file => file.Filename).ToList();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot/webapps/ROOT2");
                }
            }));
        }
Esempio n. 6
0
        public Task TestZipDeployWithMetadata()
        {
            var author      = "testAuthor";
            var authorEmail = "*****@*****.**";
            var deployer    = "testDeployer";
            var message     = "Test message for deployment";

            return(ApplicationManager.RunAsync("TestSimpleZipDeployment", async appManager =>
            {
                var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                var response = await DeployZip(appManager, files, new ZipDeployMetadata
                {
                    Author = author,
                    AuthorEmail = authorEmail,
                    Deployer = deployer,
                    Message = message
                });
                response.EnsureSuccessStatusCode();
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");
                var result = await appManager.DeploymentManager.GetResultAsync("latest");

                Assert.Equal(author, result.Author);
                Assert.Equal(authorEmail, result.AuthorEmail);
                Assert.Equal(deployer, result.Deployer);
                Assert.Equal(message, result.Message);
            }));
        }
Esempio n. 7
0
 public Task TestSimpleZipDeployment()
 {
     return(ApplicationManager.RunAsync("TestSimpleZipDeployment", async appManager =>
     {
         var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
         var response = await DeployZip(appManager, files, new ZipDeployMetadata());
         response.EnsureSuccessStatusCode();
         await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");
     }));
 }
Esempio n. 8
0
 public Task TestSimpleWarDeploymentWithCustomAppName()
 {
     return(ApplicationManager.RunAsync("TestSimpleWarDeploymentPerformsCleanDeployment", async appManager =>
     {
         var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
         var response = await DeployWar(appManager, files, new ZipDeployMetadata(), "testappname");
         response.EnsureSuccessStatusCode();
         await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot/webapps/testappname");
     }));
 }
Esempio n. 9
0
        public Task TestZipDeployment(bool isAsync)
        {
            return ApplicationManager.RunAsync("TestZipDeployment", async appManager =>
            {
                var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "zip", null, isAsync);

                var expectedFiles = files.Select(f => f.Filename).ToList();
                expectedFiles.Add("hostingstart.html");
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles.ToArray(), "site/wwwroot");
            });
        }
Esempio n. 10
0
        public Task TestAsyncZipDeployment()
        {
            return(ApplicationManager.RunAsync("TestAsyncZipDeployment", async appManager =>
            {
                // Big enough to require at least a couple polls for status until success
                var files = DeploymentTestHelper.CreateRandomFilesForZip(1000);
                var response = await DeployZip(appManager, files, new ZipDeployMetadata {
                    IsAsync = true
                });
                response.EnsureSuccessStatusCode();

                TestTracer.Trace("Confirming deployment is in progress");

                await AssertSuccesfulAsyncDeployment(appManager, files, "site/wwwroot");
            }));
        }
Esempio n. 11
0
        public Task EnsureConflictResultOnSimultaneousSyncRequest()
        {
            return(ApplicationManager.RunAsync("EnsureConflictResultOnSimultaneousSyncRequest", async appManager =>
            {
                // Big enough to run for a few seconds
                var files = DeploymentTestHelper.CreateRandomFilesForZip(1000);
                var response = await DeployZip(appManager, files, new ZipDeployMetadata {
                    IsAsync = true
                });
                response.EnsureSuccessStatusCode();

                // Immediately try another deployment
                var response2 = await DeployZip(appManager, new TestFile[0], new ZipDeployMetadata());

                Assert.Equal(HttpStatusCode.Conflict, response2.StatusCode);

                await AssertSuccesfulAsyncDeployment(appManager, files, "site/wwwroot");
            }));
        }
Esempio n. 12
0
        public Task TestSimpleWarDeploymentPerformsCleanDeployment()
        {
            return(ApplicationManager.RunAsync("TestSimpleWarDeploymentPerformsCleanDeployment", async appManager =>
            {
                // STEP 1: create a file before doing a wardeploy. We expect wardeploy to remove this file
                var fileName = "file-before-wardeployment-" + Guid.NewGuid().ToString("N");
                appManager.VfsWebRootManager.WriteAllText("webapps/ROOT/" + fileName, "some content");
                var deployedFiles = appManager.VfsWebRootManager.ListAsync("webapps/ROOT/").Result.ToList();
                Assert.Equal(1, deployedFiles.Count);
                Assert.Equal(fileName, deployedFiles[0].Name);

                // STEP 2: Perform wardeploy and check files deployed by wardeploy are the only ones that exist now
                // (in other words, check that the file created in step 1 is removed by wardeploy)
                var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                var response = await DeployWar(appManager, files, new ZipDeployMetadata());
                response.EnsureSuccessStatusCode();
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot/webapps/ROOT");
            }));
        }
Esempio n. 13
0
        public Task TestUpdateDeployStatusHeaderZipDeployment()
        {
            return(ApplicationManager.RunAsync("TestUpdateDeployStatusHeaderZipDeployment", async appManager =>
            {
                var files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                var response = await DeployZip(appManager, files, new ZipDeployMetadata {
                    TrackDeploymentProgress = true, IsAsync = true
                });
                response.EnsureSuccessStatusCode();
                Assert.True(response.Headers.Contains(Constants.ScmDeploymentIdHeader));
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");

                // If TrackDeploymentProgress=false, the response header should not contain the ScmDeploymentId
                files = DeploymentTestHelper.CreateRandomFilesForZip(10);
                response = await DeployZip(appManager, files, new ZipDeployMetadata {
                    TrackDeploymentProgress = false, IsAsync = true
                });
                response.EnsureSuccessStatusCode();
                Assert.True(!response.Headers.Contains(Constants.ScmDeploymentIdHeader));
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");
            }));
        }
Esempio n. 14
0
        public Task TestLegacyWarDeployment(bool isAsync)
        {
            return ApplicationManager.RunAsync("TestLegacyWarDeployment", async appManager =>
            {
                ConfigureSiteAsTomcatSite(appManager);

                // STEP 1A: First legacy war deployment
                var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                await DeployZippedArtifact(appManager, appManager.OneDeployManager, files1, "war", "site/wwwroot/webapps/ROOT", isAsync);

                // STEP 1B: Validate the result of the first legacy war deployment
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files1.Select(f => f.Filename).ToArray(), "site/wwwroot/webapps/ROOT");


                // STEP 2A: Second legacy war deployment
                var files2 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                await DeployZippedArtifact(appManager, appManager.OneDeployManager, files2, "war", "site/wwwroot/webapps/ROOT", isAsync);

                // STEP 2B: Validate that the second legacy war deployment cleans up the files deployes by the first deployment
                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files2.Select(f => f.Filename).ToArray(), "site/wwwroot/webapps/ROOT");
            });
        }
Esempio n. 15
0
        public Task TestZipDeployment(bool isAsync)
        {
            return(ApplicationManager.RunAsync("TestZipDeployment", async appManager =>
            {
                // Incremental deployment - not the default mode
                {
                    var initialFileName = DeploymentTestHelper.DeployRandomFilesEverywhere(appManager);

                    var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files1, "zip", null, isAsync, isClean: false);
                    var expectedFiles1 = files1.Select(f => f.Filename).ToList();
                    expectedFiles1.Add(initialFileName);
                    expectedFiles1.Add("webapps");
                    expectedFiles1.Add("hostingstart.html");
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot");
                }

                // Default deployment - clean
                {
                    var initialFileName = DeploymentTestHelper.DeployRandomFilesEverywhere(appManager);

                    var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files1, "zip", null, isAsync);
                    var expectedFiles1 = files1.Select(f => f.Filename).ToList();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot");
                }

                // Custom path
                {
                    var initialFileName = DeploymentTestHelper.DeployRandomFilesEverywhere(appManager);

                    var files1 = DeploymentTestHelper.CreateRandomFilesForZip(10);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files1, "zip", "dir1/dir2", isAsync);
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, new string [] { "dir1" }, "site/wwwroot");
                    var expectedFiles1 = files1.Select(f => f.Filename).ToList();
                    await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, expectedFiles1.ToArray(), "site/wwwroot/dir1/dir2");
                }
            }));
        }
Esempio n. 16
0
        public Task TestAsyncZipDeployment()
        {
            return(ApplicationManager.RunAsync("TestAsyncZipDeployment", async appManager =>
            {
                // Big enough to require at least a couple polls for status until success
                var files = DeploymentTestHelper.CreateRandomFilesForZip(1000);
                var response = await DeployZip(appManager, files, new ZipDeployMetadata {
                    IsAsync = true
                });
                response.EnsureSuccessStatusCode();

                TestTracer.Trace("Confirming deployment is in progress");

                DeployResult result;
                do
                {
                    result = await appManager.DeploymentManager.GetResultAsync("latest");
                    Assert.Equal(GetZipDeployer(), result.Deployer);
                    await Task.Delay(TimeSpan.FromSeconds(2));
                } while (!new[] { DeployStatus.Failed, DeployStatus.Success }.Contains(result.Status));

                await DeploymentTestHelper.AssertSuccessfulDeploymentByFilenames(appManager, files.Select(f => f.Filename).ToArray(), "site/wwwroot");
            }));
        }
Esempio n. 17
0
        public Task TestInvalidPaths()
        {
            return(ApplicationManager.RunAsync("TestInvalidPaths", async appManager =>
            {
                var files = DeploymentTestHelper.CreateRandomFilesForZip(10);

                //
                // NOTE: For each type, run a successful scenario to validate that all is good and then
                // begin with the tests for invalid paths where we expect the test to fail
                //

                // Legacy war - relative paths
                {
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "webapps/ROOT", isAsync: false, isClean: false, expectedSuccess: true);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "webapps/ROOT/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "invalid", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "webapps/app/foo", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "webapps2/app", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "webapps", isAsync: false, isClean: false, expectedSuccess: false);
                }

                // Legacy war - absolute paths
                {
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/webapps/app", isAsync: false, isClean: false, expectedSuccess: true);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/webapps/app/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/webapps/app/foo", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/webapps/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/webapps", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/webapps2/app", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "war", "/home/site/wwwroot/", isAsync: false, isClean: false, expectedSuccess: false);
                }

                // lib - absolute paths
                {
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "lib", "/home/site/libs/file.jar", isAsync: false, isClean: false, expectedSuccess: true);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "lib", "/home/site/libs/file.jar/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "lib", "/home/site/libs/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "lib", "/home/site/libs", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "lib", "/home/site/libsfile.jar", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "lib", "/home/site/lib2/file.jar", isAsync: false, isClean: false, expectedSuccess: false);
                }

                // script - absolute paths
                {
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "script", "/home/site/scripts/file.bat", isAsync: false, isClean: false, expectedSuccess: true);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "script", "/home/site/scripts/file.bat/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "script", "/home/site/scripts/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "script", "/home/site/scripts", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "script", "/home/site/scriptsfile.bat", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "script", "/home/site/scripts2/file.bat", isAsync: false, isClean: false, expectedSuccess: false);
                }

                // Static - absolute paths
                {
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "static", "/home/site/wwwroot/file.bat", isAsync: false, isClean: false, expectedSuccess: true);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "static", "/home/site/wwwroot/file.bat/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "static", "/home/site/wwwroot/", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "static", "/home/site/wwwroot", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "static", "/home/site/wwwrootfile.bat", isAsync: false, isClean: false, expectedSuccess: false);
                    await DeployZippedArtifact(appManager, appManager.OneDeployManager, files, "static", "/home/site/wwwroot2/file.bat", isAsync: false, isClean: false, expectedSuccess: false);
                }
            }));
        }