Steps To Run TestCases From External Shared Module - SujataDarekar/bw6-plugin-maven GitHub Wiki

Steps to Run Test Cases from ESM :

  1. Right click on Parent Project in Which the shared Module added as POM dependency.
  2. Run “mvn test -DrunESMTest= true” goal. This will execute all the test cases from ESM which are added as POM dependencies
  3. To run TestSuite from ESM run the following command: mvn test -DrunESMTest= true -DESMtestSuiteName=”testSuite1.bwts”
  4. To run Multiple TestSuite run following command: mvn test -DrunESMTest= true -DESMtestSuiteName=”testSuite1.bwts/testSuite2.bwts”
  5. To generate BW Coverage report usefollowing command: mvn site -DrunESMTest= true

Limitation:

  1. If the Test Case from ESM fails while running the Unit Test via approach 2, then the customer needs to import the Shared Module Project into workspace. After that they need to change the fault data and then publish it in .m2 repo and run the test case again. → It is expected that customers should Test ESM while it is being developed by creating the dummy application. Create Dummy application Generate POM for dummy application Add Shared Module Dependency using steps https://github.com/TIBCOSoftware/bw6-plugin-maven/wiki/SharedModule#shared-modules-with-maven Run the test goal on the parent project which will run the test cases from Shared Module as well.
  2. Also, if there is transitive dependency in Shared Module then it will not be covered using this approach. For example, a shared module has another Shared Module or CXF project or custom driver project dependency in POM file
  3. If ESM has customXpath then that will not be tested. For it to be tested, it requires to be in the workspace