Forum Discussion

kathir_43's avatar
kathir_43
Contributor
3 years ago

Testcase execution distribution in multiple machines using TestComplete

we have developed a framework combination keyword and data driven framework. The Framework will have main class which will looks for the test case which marked as Yes and execute the corresponding Keywords. The Keywords will basic modules like login , logout ..etc .The test data will be mapped to the Testcase and will be passed on run time. Under Execution entity we have only one class (i.e. scripts/main).

Our need is to perform the parallel distributed testing in multiple machines through Jenkins server. we have created a job by following the documentation below:

https://support.smartbear.com/testcomplete/docs/working-with/integration/jenkins/pipeline.html

 Able to successfully configure machines but on execution the same test case is getting executed in both machines.

Sample scenario

TestcaseNameExecutionKeyword1Keword2Keyword3
TC001YesloginCreateorderLogout
TC002YesloginDeletedOrderLogout
TC003NoLoginLogout 

 

In the Above scenario, TC001 is getting executed in both machines after that tc002.

I wanted to distribute test cases in machines like tc001 needs to be executed in machine 1 and tc002 in machine 2. Can someone help with this?

 

4 Replies

  • Are you executing via a Jenkins Pipeline? I think we just need to declare which test gets executed on which node. 

    IE Node 1 is declared as: 
    stage('Tests on RemoteAgent1'){
      agent{
        label 'RemoteAgent1'
      }
      steps{
        testcompletetest credentialsId: 'tester',
          executorType: 'TE',
          launchType: 'lcRoutine',
          project: 'TestProject',
          routine: 'Test1',
          suite: 'TestProject1\\TestProject1.pjs',
          unit: 'Unit1',
          useTCService: true
      }
    }
    https://support.smartbear.com/testcomplete/docs/testing-with/deprecated/distributed/migrate/jenkins.html 
    Look at 1.1 and below 

    • kathir_43's avatar
      kathir_43
      Contributor

      In the Above scenario, Test1 will corresponds to same test runner file . So same testcase is getting executed in machines. we need to distribute the test case in different machines for parallel mode.

      • mattb's avatar
        mattb
        Staff

        So if you want to execute on multiple machines in parallel it would require multiple testrunner arguments.

        Stage 1 would be on node 1 
        Stage 2 on node 2

        We just need to call the parallel jenkins argument so each stage executes in parallel.