예제 #1
0
        public override Dictionary <string, string> GetTaskProperties()
        {
            LauncherParamsBuilder builder = new LauncherParamsBuilder();

            builder.SetRunType(RunType.AlmLabManagement);
            builder.SetAlmServerUrl(ALMServerPath);
            builder.SetAlmUserName(ALMUserName);
            builder.SetAlmPassword(ALMPassword);
            builder.SetAlmDomain(ALMDomain);
            builder.SetAlmProject(ALMProject);
            builder.SetBuildNumber(BuildNumber);

            switch (TestRunType)
            {
            case "testSet":
                builder.SetTestRunType(RunTestType.TEST_SUITE);
                break;

            case "buildVerificationSuite":
                builder.SetTestRunType(RunTestType.BUILD_VERIFICATION_SUITE);
                break;
            }

            if (!string.IsNullOrEmpty(ALMTestSet))
            {
                int i = 1;
                foreach (string testSet in ALMTestSet.Split('\n'))
                {
                    builder.SetTestSet(i++, testSet.Replace(@"\", @"\\"));
                }
            }
            else
            {
                builder.SetAlmTestSet("");
            }


            if (UseCDA)
            {
                builder.SetDeploymentAction(DeploymentAction);
                builder.SetDeployedEnvironmentName(DeploymentEnvironmentName);
                builder.SetDeprovisioningAction(DeprovisioningAction);
            }

            //set ALM mandatory parameters
            builder.SetAlmTimeout(TimeslotDuration);
            builder.SetAlmRunMode(AlmRunMode.RUN_LOCAL);
            builder.SetAlmRunHost("localhost");

            /*builder.SetUploadArtifact(UploadArtifact);
             * builder.SetArtifactType(ArtType);
             * builder.SetReportName(ReportFileName);
             * builder.SetArchiveName(ArchiveName);
             * builder.SetStorageAccount(StorageAccount);
             * builder.SetContainer(Container);*/

            return(builder.GetProperties());
        }
예제 #2
0
        public override Dictionary <string, string> GetTaskProperties()
        {
            LauncherParamsBuilder builder = new LauncherParamsBuilder();

            builder.SetRunType(RunType.Alm);
            builder.SetAlmServerUrl(ALMServerPath);
            builder.SetSSOEnabled(SSOEnabled);
            builder.SetClientID(ClientID);
            builder.SetApiKeySecret(ApiKeySecret);
            builder.SetAlmUserName(ALMUserName);
            builder.SetAlmPassword(ALMPassword);
            builder.SetAlmDomain(ALMDomain);
            builder.SetAlmProject(ALMProject);
            builder.SetAlmRunHost(ALMRunHost);
            builder.SetAlmTimeout(TimeOut);
            builder.SetBuildNumber(BuildNumber);

            switch (RunMode)
            {
            case "runLocally":
                builder.SetAlmRunMode(AlmRunMode.RUN_LOCAL);
                break;

            case "runOnPlannedHost":
                builder.SetAlmRunMode(AlmRunMode.RUN_PLANNED_HOST);
                break;

            case "runRemotely":
                builder.SetAlmRunMode(AlmRunMode.RUN_REMOTE);
                break;
            }

            if (!string.IsNullOrEmpty(ALMTestSet))
            {
                int i = 1;
                foreach (string testSet in ALMTestSet.Split('\n'))
                {
                    builder.SetTestSet(i++, testSet.Replace(@"\", @"\\"));
                }
            }
            else
            {
                builder.SetAlmTestSet("");
            }

            /* builder.SetUploadArtifact(UploadArtifact);
             * builder.SetArtifactType(ArtType);
             * builder.SetReportName(ReportFileName);
             * builder.SetArchiveName(ArchiveName);
             * builder.SetStorageAccount(StorageAccount);
             * builder.SetContainer(Container);*/

            return(builder.GetProperties());
        }
        public override Dictionary <string, string> GetTaskProperties()
        {
            LauncherParamsBuilder builder = new LauncherParamsBuilder();

            builder.SetRunType(RunType.AlmLabManagement);
            builder.SetAlmServerUrl(ALMServerPath);
            builder.SetSSOEnabled(IsSSO);
            builder.SetClientID(ClientID);
            builder.SetApiKeySecret(ApiKeySecret);
            builder.SetAlmUserName(ALMUserName);
            builder.SetAlmPassword(ALMPassword);
            builder.SetAlmDomain(ALMDomain);
            builder.SetAlmProject(ALMProject);
            builder.SetBuildNumber(BuildNumber);

            switch (TestRunType)
            {
            case C.TEST_SET:
                builder.SetTestRunType(RunTestType.TEST_SUITE);
                break;

            case C.BVS:
                builder.SetTestRunType(RunTestType.BUILD_VERIFICATION_SUITE);
                break;
            }

            if (!string.IsNullOrEmpty(ALMEntityId))
            {
                int i = 1;
                foreach (string testSet in ALMEntityId.Split(C.LINE_FEED))
                {
                    builder.SetTestSet(i++, testSet.Replace(@"\", @"\\"));
                }
            }
            else
            {
                builder.SetAlmTestSet(string.Empty);
            }

            //set ALM mandatory parameters
            builder.SetAlmTimeout(TimeslotDuration);
            builder.SetAlmRunMode(AlmRunMode.RUN_PLANNED_HOST);
            builder.SetAlmRunHost(string.Empty);

            return(builder.GetProperties());
        }
예제 #4
0
        public override Dictionary <string, string> GetTaskProperties()
        {
            LauncherParamsBuilder builder = new LauncherParamsBuilder();

            builder.SetRunType(RunType.Alm);
            builder.SetAlmServerUrl(ALMServerPath);
            builder.SetAlmUserName(ALMUserName);
            builder.SetAlmPassword(ALMPassword);
            builder.SetAlmDomain(ALMDomain);
            builder.SetAlmProject(ALMProject);
            builder.SetAlmRunHost(ALMRunHost);
            builder.SetAlmTimeout(TimeOut);

            switch (RunMode)
            {
            case "runLocally":
                builder.SetAlmRunMode(AlmRunMode.RUN_LOCAL);
                break;

            case "runOnPlannedHost":
                builder.SetAlmRunMode(AlmRunMode.RUN_PLANNED_HOST);
                break;

            case "runRemotely":
                builder.SetAlmRunMode(AlmRunMode.RUN_REMOTE);
                break;
            }

            if (!string.IsNullOrEmpty(ALMTestSet))
            {
                int i = 1;
                foreach (string testSet in ALMTestSet.Split('\n'))
                {
                    builder.SetTestSet(i++, testSet.Replace(@"\", @"\\"));
                }
            }
            else
            {
                builder.SetAlmTestSet("");
            }

            return(builder.GetProperties());
        }