public async Task TestDownloadApplicationBinaries()
        {
            const string testName        = nameof(TestDownloadApplicationBinaries);
            const string testFileContent = "some content";

            await UploadTestApplicationBinaries(ConflictResolutionMode.FailIfBinariesExist, testFileContent);

            string localPath = await CreateTestTempDirectory(testName);

            await _deploymentRepository.DownloadApplicationBinaries(TestAppIdentity, localPath, ConflictResolutionMode.FailIfBinariesExist);

            VerifyBinariesExist(localPath, testFileContent);
        }
Ejemplo n.º 2
0
 public async Task DownloadApplication(AppIdentity appIdentity)
 {
     try
     {
         string destPath = Path.Combine(_applicationRootPath,
                                        ApplicationUtils.GetApplicationRelativePath(appIdentity));
         await
         _deploymentRepository.DownloadApplicationBinaries(appIdentity, destPath,
                                                           ConflictResolutionMode.OverwriteExistingBinaries);
     }
     catch (BinariesNotFoundException)
     {
         Trace.TraceError(
             $"{appIdentity} could not be downloaded because it was not found in the Yams repository");
     }
 }