Forum Discussion

lauravachon's avatar
lauravachon
Contributor
6 years ago

Ready api maven plugin - how to execute all suites in a composite project

I am trying to run all of the test suites in my ready-api project using the maven plugin. If I do not specify a test suite directly, I get the following stack trace.

 

java.lang.ClassNotFoundException: com.sun.jdi.request.EventRequest
at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at com.eviware.soapui.tools.DebugSupport.<clinit>(DebugSupport.java:19)
at com.eviware.soapui.impl.wsdl.teststeps.registry.GroovyScriptStepFactory.buildTestStep(GroovyScriptStepFactory.java:38)
at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCase.createTestStepFromConfig(WsdlTestCase.java:390)
at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCase.<init>(WsdlTestCase.java:162)
at com.eviware.soapui.impl.wsdl.WsdlTestCasePro.<init>(WsdlTestCasePro.java:64)
at com.eviware.soapui.impl.wsdl.WsdlTestSuitePro.buildTestCase(WsdlTestSuitePro.java:85)
at com.eviware.soapui.impl.wsdl.WsdlTestSuitePro.buildTestCase(WsdlTestSuitePro.java:1)
at com.eviware.soapui.impl.wsdl.WsdlTestSuite.<init>(WsdlTestSuite.java:115)
at com.eviware.soapui.impl.wsdl.WsdlTestSuitePro.<init>(WsdlTestSuitePro.java:48)
at com.eviware.soapui.impl.wsdl.WsdlProjectPro.buildTestSuite(WsdlProjectPro.java:1146)
at com.eviware.soapui.impl.wsdl.WsdlProjectPro.loadProject(WsdlProjectPro.java:416)
at com.eviware.soapui.impl.wsdl.WsdlProject.<init>(WsdlProject.java:284)
at com.eviware.soapui.impl.wsdl.WsdlProject.<init>(WsdlProject.java:263)
at com.eviware.soapui.impl.wsdl.WsdlProjectPro.<init>(WsdlProjectPro.java:193)
at com.eviware.soapui.impl.wsdl.WsdlProjectProFactory.createNew(WsdlProjectProFactory.java:112)
at com.eviware.soapui.impl.wsdl.WsdlProjectProFactory.createNew(WsdlProjectProFactory.java:1)
at com.smartbear.ready.cmd.runner.AbstractSoapUIRunner.getWsdlProject(AbstractSoapUIRunner.java:385)
at com.smartbear.ready.cmd.runner.SoapUITestCaseRunner.runRunner(SoapUITestCaseRunner.java:325)
at com.smartbear.ready.cmd.runner.pro.SoapUIProTestCaseRunner.runRunner(SoapUIProTestCaseRunner.java:97)
at com.smartbear.ready.cmd.runner.AbstractSoapUIRunner.run(AbstractSoapUIRunner.java:264)
at com.eviware.soapui.maven2.TestMojo.execute(TestMojo.java:152)

  • lauravachon's avatar
    lauravachon
    6 years ago

    I think I may have fixed this by upgrading the soapUi version to 2.7.0.

  • Nastya_Khovrina's avatar
    Nastya_Khovrina
    SmartBear Alumni (Retired)

    Hi,

     

    Can you please provide us with the pom.xml file which you use?

    • lauravachon's avatar
      lauravachon
      Contributor

      <?xml version="1.0" encoding="UTF-8"?>
      <project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns="http://maven.apache.org/POM/4.0.0"
      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
      <modelVersion>4.0.0</modelVersion>

      <groupId>groupId</groupId>
      <artifactId>artifactId</artifactId>
      <version>1.0-SNAPSHOT</version>

      <properties>
      <unpackdir>${project.build.directory}/resources/testdata</unpackdir>
      <projectFile>CompositeProjectDir</projectFile>
      <outputDirectory>${project.build.directory}/test-reports</outputDirectory>
      <environment>QA</environment>
      <soapui.home>C:\Program Files\SmartBear\ReadyAPI-2.1.0</soapui.home>
      <testSuite>UmlerLookUp</testSuite>
      </properties>

      <build>
      <plugins>
      <plugin>
      <groupId>com.smartbear</groupId>
      <artifactId>ready-api-maven-plugin</artifactId>
      <version>2.1.0</version>
      <configuration>
      <readyApiProperties>
      <soapui.home>${soapui.home}</soapui.home>
      </readyApiProperties>
      <testFailIgnore>true</testFailIgnore>
      <outputFolder>${outputDirectory}</outputFolder>
      <junitReport>true</junitReport>
      <exportAll>false</exportAll>
      <printReport>false</printReport>
      <projectProperties>
      <environment>${environment}</environment>
      </projectProperties>
      </configuration>
      <executions>
      <execution>
      <id>CrmsSoapTests</id>
      <phase>test</phase>
      <goals>
      <goal>test</goal>
      </goals>
      <configuration>
      <projectFile>${projectFile}</projectFile>
      <!-- <testSuite>${testSuite}</testSuite>-->
      <!-- <junitReport>true</junitReport>-->
      <!-- <exportAll>false</exportAll>-->
      <!-- <printReport>false</printReport>-->
      </configuration>
      </execution>
      </executions>
      </plugin>
      </plugins>
      </build>

      <dependencies>
      <dependency>
      <groupId>com.oracle</groupId>
      <artifactId>ojdbc8</artifactId>
      <version>12.2.0.1</version>
      </dependency>
      <dependency>
      <groupId>com.smartbear</groupId>
      <artifactId>ready-api-soapui</artifactId>
      <version>2.1.0</version>
      </dependency>
      <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
      <version>1.2.3</version>
      </dependency>
      </dependencies>
      </project>

      • Nastya_Khovrina's avatar
        Nastya_Khovrina
        SmartBear Alumni (Retired)

        lauravachon 

        Sorry, I wasn't clear, please provide us with the pom.xml file for which you get this stack trace.

        Do it have these properties?

        <properties>
        <unpackdir>${project.build.directory}/resources/testdata</unpackdir>
        <projectFile>CompositeProjectDir</projectFile>
        <outputDirectory>${project.build.directory}/test-reports</outputDirectory>
        <environment>QA</environment>
        <soapui.home>C:\Program Files\SmartBear\ReadyAPI-2.1.0</soapui.home>
        </properties>

         

        Also, I see that you use ReadyAPI 2.1.0, please try the latest version of ReadyAPI which is 2.7.0 now: 

        https://support.smartbear.com/downloads/readyapi/