public void Test_GetTargetFolde_Throws_EnvInfo_null()
        {
            var schedulerAppProjectInfo =
            new SchedulerAppProjectInfo(
              _ProjectName,
              _ArtifactsRepositoryName,
              _ArtifactsRepositoryDirName,
              _ArtifactsAreNotEnvirionmentSpecific,
              _SchedulerAppName,
              _SchedulerAppDirName,
              _SchedulerAppExeName,
              _SchedulerAppUserId,
              _ScheduledHour,
              _ScheduledMinute,
              _ExecutionTimeLimitInMinutes);

              Assert.Throws<ArgumentNullException>(() => schedulerAppProjectInfo.GetTargetFolders(null));
        }
        public void Test_GetTargetFolde_RunsProperly_WhenAllIsWell()
        {
            string machine = Environment.MachineName;
              const string baseDirPath = "c:\\basedir";

              var envInfo =
            new EnvironmentInfo(
              "name",
              true,
              "templates",
              "appservermachine",
              "failover",
              new[] { "webmachine" },
              "terminalmachine",
              new[] { machine },
              new[] { machine },
              baseDirPath,
              "webbasedir",
              "c:\\scheduler",
              "terminal",
              false,
              TestData.EnvironmentUsers,
              TestData.AppPoolInfos,
              TestData.DatabaseServers,
              TestData.ProjectToFailoverClusterGroupMappings,
              TestData.WebAppProjectConfigurationOverrides,
              TestData.DbProjectConfigurationOverrides,
              "terminalAppsShortcutFolder",
              "artifactsDeploymentDirPath",
              "domain-name",
              TestData.CustomEnvMachines);

              var schedulerAppProjectInfo =
            new SchedulerAppProjectInfo(
              _ProjectName,
              _ArtifactsRepositoryName,
              _AllowedEnvironmentNames,
              _ArtifactsRepositoryDirName,
              _ArtifactsAreNotEnvirionmentSpecific,
              _SchedulerAppDirName,
              _SchedulerAppExeName,
              new List<SchedulerAppTask>
              {
            new SchedulerAppTask(
              _SchedulerAppName,
              _SchedulerAppName,
              _SchedulerAppUserId,
              _ScheduledHour,
              _ScheduledMinute,
              _ExecutionTimeLimitInMinutes,
              _Repetition)
              });

              List<string> targetFolders =
            schedulerAppProjectInfo.GetTargetFolders(_objectFactoryFake.Object, envInfo)
              .ToList();

              Assert.IsNotNull(targetFolders);
              Assert.AreEqual(1, targetFolders.Count);
              Assert.AreEqual("\\\\" + machine + "\\c$\\scheduler\\" + _SchedulerAppDirName, targetFolders[0]);
        }
        public void Test_GetTargetFolde_RunsProperly_WhenAllIsWell()
        {
            string machine = Environment.MachineName;
              const string baseDirPath = "c:\\basedir";

              var envInfo =
            new EnvironmentInfo(
              "name",
              "templates",
              machine,
              "failover",
              new[] { "webmachine" },
              "terminalmachine",
              "databasemachine",
              baseDirPath,
              "webbasedir",
              "c:\\scheduler",
              "terminal",
              false,
              _EnvironmentUsers,
              _ProjectToFailoverClusterGroupMappings);

              var schedulerAppProjectInfo =
            new SchedulerAppProjectInfo(
              _ProjectName,
              _ArtifactsRepositoryName,
              _ArtifactsRepositoryDirName,
              _ArtifactsAreNotEnvirionmentSpecific,
              _SchedulerAppName,
              _SchedulerAppDirName,
              _SchedulerAppExeName,
              _SchedulerAppUserId,
              _ScheduledHour,
              _ScheduledMinute,
              _ExecutionTimeLimitInMinutes);

              List<string> targetFolders =
            schedulerAppProjectInfo.GetTargetFolders(envInfo)
              .ToList();

              Assert.IsNotNull(targetFolders);
              Assert.AreEqual(1, targetFolders.Count);
              Assert.AreEqual("\\\\" + machine + "\\c$\\scheduler\\" + _SchedulerAppDirName, targetFolders[0]);
        }