Forum Discussion
see the error:
java.lang.ClassNotFoundException: com.oracle.jdbc.Driver
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
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>com.xxx.dsd</groupId>
<artifactId>eAPI-Tests</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>eAPI-Test</name>
<description>A project to test eAPIS</description>
<build>
<plugins>
<plugin>
<groupId>com.smartbear.soapui</groupId>
<artifactId>soapui-pro-maven-plugin</artifactId>
<version>5.1.1</version>
<dependencies>
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc</artifactId>
<version>11.1.0.6.0</version>
</dependency>
<dependency>
<groupId>org.reflections</groupId>
<artifactId>reflections</artifactId>
<version>0.9.9-RC1</version>
</dependency>
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>3.10-FINAL</version>
</dependency>
</dependencies>
<configuration>
<tool>wsi,axis1,axis2</tool>
<projectFile>src/test/resources</projectFile>
<junitReport>true</junitReport>
<outputFolder>target/reports</outputFolder>
<testSuite>SureSwipeTSuite</testSuite>
<settingsFile>eAPI-Tests/soapui-settings.xml</settingsFile>
</configuration>
<executions>
<execution>
<phase>test</phase>
<goals>
<goal>test</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Thsis is my POM and it seems to fail eventhough I gave the ODBC jar as a plugin dependency and the jar is downlaoded . I also checked the jar file has the required class.
Hi,
It sounds like you only need to add your DB driver jar to the external libraries (ext folder) that Maven expects. Did you see a message like this at the maven script is run:
16:28:15,343 WARN [SoapUI] Missing folder [.../ext] for external libraries
?
If so either add the db driver jar file to this location or alternatively specify the location of the 'ext' folder (containing the db driver jar) with the following parameter:
mvn integration-test "-Dsoapui.ext.libraries=src/test/resources"
Hope this helps,
Cheers,
Rupert