Can't run maven tests via terminal | Failed to execute goal - java

I am trying to use maven to run my unit tests in terminal.
When I run mvn clean test or mvn test I get the following output:
user#user:~/Documents/git/projectname$ mvn test
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.google.inject.internal.cglib.core.$ReflectUtils$1 (file:/usr/share/maven/lib/guice.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain)
WARNING: Please consider reporting this to the maintainers of com.google.inject.internal.cglib.core.$ReflectUtils$1
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building project name 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # projectname ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # projectname ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # projectname ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # projectname ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) # projectname ---
[INFO] Surefire report directory: /home/user/Documents/git/QA-projectname/target/surefire-reports
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/surefire/surefire-junit4/2.12.4/surefire-junit4-2.12.4.pom
[INFO] Failure detected.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.258 s
[INFO] Finished at: 2018-06-13T15:36:31-06:00
[INFO] Final Memory: 13M/54M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project projectname: Unable to generate classpath: org.apache.maven.artifact.resolver.ArtifactResolutionException: Unable to get dependency information for org.apache.maven.surefire:surefire-junit4:jar:2.12.4: Failed to retrieve POM for org.apache.maven.surefire:surefire-junit4:jar:2.12.4: Could not transfer artifact org.apache.maven.surefire:surefire-junit4:pom:2.12.4 from/to central (https://repo.maven.apache.org/maven2): java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
[ERROR] org.apache.maven.surefire:surefire-junit4:jar:2.12.4
[ERROR]
[ERROR] from the specified remote repositories:
[ERROR] central (https://repo.maven.apache.org/maven2, releases=true, snapshots=false)
[ERROR] Path to dependency:
[ERROR] 1) dummy:dummy:jar:1.0
[ERROR]
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
I have also tried to run a single test with mvn test -Dtest=testname but I get the same error.
Here is my pom.xml file:
<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>groupidhere</groupId>
<artifactId>artifactidhere</artifactId>
<version>0.0.1-SNAPSHOT</version>
<dependencies>
<dependency>
<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>4.0.0</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>21.0</version>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-java</artifactId>
<version>3.0.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven.surefire</groupId>
<artifactId>surefire</artifactId>
<version>2.21.0</version>
<type>pom</type>
</dependency>
</dependencies>
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>
<name>Small Store Regression</name>
<description>description here</description>
</project>
Here is an example of one of my tests:
package loginPurchase;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.Test;
import PageObjects.CartScreen;
import PageObjects.HomeScreen;
import testBase.TestBase;
import java.math.BigDecimal;
import static org.junit.Assert.assertTrue;
public class ProductTaxPurchases extends TestBase {
#Before
public void setUp() throws Exception {
mobileSetup();
}
#AfterClass
public static void tearDown() throws Exception {
mdriver.quit();
mdriver = null;
}
//The purpose of this test is to add a taxed product to a cart and verify the taxes are correct | and purchase by CC
#Test
public void purchaseTaxedProductByCredit() throws InterruptedException {
HomeScreen hs = new HomeScreen(mdriver);
CartScreen cs = new CartScreen(mdriver);
hs.clickMenu("TestMenuB")
.clickMenuItem("ChrisTaxProduct");
String subTotal = cs.getSubTotal();
String taxAmount = cs.getTax();
String grandTotal = cs.getGrandTotal();
BigDecimal currentSubTotal = new BigDecimal(subTotal);
BigDecimal currentTaxTotal = new BigDecimal(taxAmount);
BigDecimal currentGrandTotal = new BigDecimal(grandTotal);
BigDecimal expectedGrandTotal = currentSubTotal.add(currentTaxTotal);
assertTrue(currentGrandTotal.compareTo(expectedGrandTotal) == 0);
cs.clickPayByCreditCard()
.swipeApprovedCard()
.clickNoReceipt();
}
Second Edit:
Here is the output of mvn dependency::tree
[ERROR] No plugin found for prefix 'dependency' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (/home/chris/.m2/repository), central (https://repo.maven.apache.org/maven2)] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/NoPluginFoundForPrefixException
Third edit:
I can successfully run mvn clean test on my windows 10 machine and it works as expected. This problem exists on my Ubuntu 18.04 machine.
Any ideas of what I can do to fix this? I normally run my tests in intellij idea and they run just fine. But I am needing to get these tests ready for upload in Microsoft App Center.

The problem exists with Ubuntu 18.04.
I ran sudo rm /etc/ssl/certs/java/cacerts and then sudo update-ca-certificates -f and this fixed my issue in kubuntu 18.04.

Related

ERROR Failed to execute goal io.quarkus:quarkus-maven-plugin:1.13.2.Final:dev (default-cli) on project code-with-quarkus:

when I use the command mvn clean quarkus: dev, I get the following response from the terminal in intellij:
E:\api-hard-lot>mvn clean quarkus:dev
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< org.acme:code-with-quarkus >---------------------
[INFO] Building code-with-quarkus 1.0.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # code-with-quarkus ---
[INFO] Deleting E:\api-hard-lot\target
[INFO]
[INFO] --- quarkus-maven-plugin:1.13.2.Final:dev (default-cli) # code-with-quarkus ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 31 source files to E:\api-hard-lot\target\classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.052 s
[INFO] Finished at: 2021-04-25T12:02:55-03:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal io.quarkus:quarkus-maven-plugin:1.13.2.Final:dev (default-cli) on project code-with-quarkus: Fatal error
compiling: invalid target release: 11 -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
'cmd' is not recognized as an internal command
or external, an operable program or a batch file.
Your project was created using JDK 11 and thus mandates JDK 11 while you are trying to build it with a JDK inferior to 11.
Either update your JDK (recommended) or adjust your project to be JDK 8 compatible (replace occurrences of 11 with 1.8 in your pom file).
thanks guys thats exactly my solution i alter to jdk 8 and
in pom
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
and
in code-with-quarkus

Running an Eclipse Java Maven project from a Windows (DOS) shell

Summary: How to run an Eclipse Java Maven Project outside of Eclipse
Details:
I am a Maven newbie and I have created a very simple Maven project in Eclipse.
The Package Explorer view of my project is as follows:
The source code for the two simple Java files is as follows:
package Pkg01;
public class Calculator
{
public double add(double number1, double number2)
{
return number1 + number2;
}
public static void main(String[] args) {
Calculator calculator = new Calculator();
System.out.println(calculator.add(100, 200));
}
}
and
package Pkg01;
import junit.framework.TestCase;
public class TestCalculator extends TestCase
{
public void testAdd()
{
Calculator calculator = new Calculator();
double result = calculator.add(10, 50);
assertEquals(60, result, 0);
}
}
From within Eclipse I am able to run the Java Application, the Junit Test and the Maven test, without any issues.
My question is how can I invoke the mvn command from the DOS shell so that I can:
Run the Java Application
Run the Junit Test
Run the Maven test
BTW running mvn exec:java from the parent directory of the project is not executing the Java application for me.
My pom.xml file looks like this:
<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>org.newbie</groupId>
<artifactId>Stackoverflow</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Stackoverflow</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
</project>
mvn exec:java gives the following error:
[INFO] Scanning for projects...
[INFO]
[INFO] ----------------------< org.newbie:Stackoverflow >----------------------
[INFO] Building Stackoverflow 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- exec-maven-plugin:1.6.0:java (default-cli) # Stackoverflow ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.957 s
[INFO] Finished at: 2019-11-05T22:47:00-06:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.6.0:java (default-cli) on project Stackoverflow: The parameters 'mainClass' for goal org.codehaus.mojo:exec-maven-plugin:1.6.0:java are missing or invalid -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginParameterException
Here are the reasons why I feel that my question is not a duplicate.
I created a very simple project with maven-archetype-quickstart and my environment is correct because everything {i.e. (1) Run the Java Application, (2) Run the Junit Test and (3) Run the Maven test} works for me within the Eclipse IDE environment. The other poster was having trouble executing, which I don’t.
The comments that the other poster received were mainly for fixing his environment to get it running. I don't have that issue since, as already mentioned, everything works for me within the Eclipse IDE environment.
All I am asking is what I need to do get the following things working from the command shell:
Running the Java Application
Running the Junit Test
Running the Maven test
The error message states parameters 'mainClass' for goal org.codehaus.mojo:exec-maven-plugin.If you look at the exec:java documentation the required parameter is mainClass
I don't see exec-maven-plugin being configured in your pom.xml so you could execute Java programs using below command
mvn exec:java -Dexec.mainClass="com.example.Main"
Make sure you have compiled you code either using mvn compile or mvn install command before running mvn exec.. command
C:\data\development\app_code\my-app>mvn exec:java -Dexec.mainClass="com.mycompany.app.App"
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building my-app 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- exec-maven-plugin:1.6.0:java (default-cli) # my-app ---
300.0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.960 s
[INFO] Finished at: 2019-11-06T09:55:23+00:00
[INFO] Final Memory: 9M/116M
[INFO] ------------------------------------------------------------------------
C:\Sachin\data\development\app_code\test-maven\my-app>
For Junit testing you could call mvn test which would give you the test results status similar to your Eclipse IDE
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running com.mycompany.app.AppTest
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.099 sec
Results :
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.198 s
[INFO] Finished at: 2019-11-06T09:55:58+00:00
[INFO] Final Memory: 19M/160M
[INFO] ------------------------------------------------------------------------
I do see the same details being mentioned in the link by Karthikeyan Vaithilingam
Reference:
https://www.mojohaus.org/exec-maven-plugin/usage.html
OP Addendum
You have provided the solution for:
1. Running the Java Application
3. Running the Maven test
From the IDE I can also invoke:
2. Running the Junit Test
Admittedly this is very similar to 3. Running the Maven test but the output looks different.
Is there a way to do that from outside of the IDE environment?

Getting error while running Maven Project from Jenkins even though same setup works on Locally

Description : Same POM works locally with same suit but when i am swtiching to Jenkins execution, it shows the errors. Can anyone please help me to understand why this may happening?
Error Message recevied while running job from jenkins :
Started by user unknown or anonymous
[EnvInject] - Loading node environment variables.
Building in workspace /var/lib/jenkins/workspace/WanderlyAutomationSuite
> git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
> git config remote.origin.url git#github.com:orionhcs/automation-tests.git # timeout=10
Fetching upstream changes from git#github.com:orionhcs/automation-tests.git
> git --version # timeout=10
using GIT_SSH to set credentials
> git fetch --tags --progress git#github.com:orionhcs/automation-tests.git +refs/heads/*:refs/remotes/origin/*
> git rev-parse refs/remotes/origin/master^{commit} # timeout=10
> git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
Checking out Revision 53f5d799bb2578706e48d80e1f428ca5a324e96c (refs/remotes/origin/master)
> git config core.sparsecheckout # timeout=10
> git checkout -f 53f5d799bb2578706e48d80e1f428ca5a324e96c
Commit message: "updated the code"
> git rev-list --no-walk 53f5d799bb2578706e48d80e1f428ca5a324e96c # timeout=10
[WanderlyAutomationSuite] $ /bin/sh -xe /tmp/jenkins8894762653318384960.sh
+ export M2_HOME=/srv/maven/
Parsing POMs
Established TCP socket on 37493
[WanderlyAutomationSuite] $ /usr/lib/jvm/java-8-openjdk-amd64//bin/java -cp /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven35-agent-1.12.jar:/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.5.4/boot/plexus-classworlds-2.5.2.jar:/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.5.4/conf/logging jenkins.maven3.agent.Maven35Main /var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.5.4 /var/cache/jenkins/war/WEB-INF/lib/remoting-3.19.jar /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven35-interceptor-1.12.jar /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven3-interceptor-commons-1.12.jar 37493
<===[JENKINS REMOTING CAPACITY]===>channel started
Executing Maven: -B -f /var/lib/jenkins/workspace/WanderlyAutomationSuite/pom.xml compile test
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< Wanderly:WanderlyScenarios >---------------------
[INFO] Building WanderlyScenarios 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/workspace/WanderlyAutomationSuite/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/workspace/WanderlyAutomationSuite/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/workspace/WanderlyAutomationSuite/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-surefire-plugin:2.18.1:test (default-test) # WanderlyScenarios ---
[INFO] No tests to run.
[INFO] Surefire report directory: /var/lib/jenkins/workspace/WanderlyAutomationSuite/target/surefire-reports
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running TestSuite
Results :
Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
[JENKINS] Recording test results
hudson.AbortException: Test reports were found but none of them are new. Did leafNodes run?
For example, /var/lib/jenkins/workspace/WanderlyAutomationSuite/target/surefire-reports/TEST-TestSuite.xml is 37 min old
at hudson.tasks.junit.TestResult.parse(TestResult.java:266)
at hudson.tasks.junit.TestResult.parse(TestResult.java:231)
at hudson.maven.reporters.SurefireArchiver.postExecute(SurefireArchiver.java:148)
at hudson.maven.Maven3Builder$MavenExecutionListener.recordMojoEnded(Maven3Builder.java:629)
at hudson.maven.Maven3Builder$MavenExecutionListener.mojoFailed(Maven3Builder.java:662)
at hudson.maven.Maven3Builder$JenkinsEventSpy.onEvent(Maven3Builder.java:306)
at org.apache.maven.eventspy.internal.EventSpyDispatcher.onEvent(EventSpyDispatcher.java:104)
at org.apache.maven.eventspy.internal.EventSpyExecutionListener.mojoFailed(EventSpyExecutionListener.java:138)
at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire(DefaultExecutionEventCatapult.java:90)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:220)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:154)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:146)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:305)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:192)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:105)
at org.jvnet.hudson.maven3.launcher.Maven35Launcher.main(Maven35Launcher.java:130)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at jenkins.maven3.agent.Maven35Main.launch(Maven35Main.java:176)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:139)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:70)
at hudson.remoting.UserRequest.perform(UserRequest.java:212)
at hudson.remoting.UserRequest.perform(UserRequest.java:54)
at hudson.remoting.Request$2.run(Request.java:369)
at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.440 s
[INFO] Finished at: 2019-03-06T12:25:02-08:00
[INFO] ------------------------------------------------------------------------
Waiting for Jenkins to finish collecting data
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test (default-test) on project WanderlyScenarios: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test failed: There was an error in the forked process
[ERROR] org.testng.TestNGException:
[ERROR] Cannot find class in classpath: com.scenarios.Wanderly_ApplyJob_Scenario
[ERROR] at org.testng.xml.XmlClass.loadClass(XmlClass.java:81)
[ERROR] at org.testng.xml.XmlClass.init(XmlClass.java:73)
[ERROR] at org.testng.xml.XmlClass.<init>(XmlClass.java:59)
[ERROR] at org.testng.xml.TestNGContentHandler.startElement(TestNGContentHandler.java:546)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:182)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1339)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2784)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:842)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:771)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:327)
[ERROR] at javax.xml.parsers.SAXParser.parse(SAXParser.java:195)
[ERROR] at org.testng.xml.XMLParser.parse(XMLParser.java:38)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:16)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:9)
[ERROR] at org.testng.xml.Parser.parse(Parser.java:172)
[ERROR] at org.testng.TestNG.initializeSuitesAndJarFile(TestNG.java:300)
[ERROR] at org.testng.TestNG.run(TestNG.java:1021)
[ERROR] at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:295)
[ERROR] at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:84)
[ERROR] at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:90)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException
[JENKINS] Archiving /var/lib/jenkins/workspace/WanderlyAutomationSuite/pom.xml to Wanderly/WanderlyScenarios/0.0.1-SNAPSHOT/WanderlyScenarios-0.0.1-SNAPSHOT.pom
channel stopped
Finished: FAILURE
Below is the POM file which has created to run the script :
http://maven.apache.org/xsd/maven-4.0.0.xsd">
4.0.0
<groupId>Wanderly</groupId>
<artifactId>WanderlyScenarios</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>WanderlyScenarios</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.18.1</version>
<configuration>
<suiteXmlFiles>
<suiteXmlFile>testngExecutor.xml</suiteXmlFile>
</suiteXmlFiles>
<testFailureIgnore>true</testFailureIgnore>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-chrome-driver -->
<!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-chrome-driver -->
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-chrome-driver</artifactId>
<version>3.14.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.testng/testng -->
<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<version>6.9.9</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-server</artifactId>
<version>2.46.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi</artifactId>
<version>3.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi-ooxml -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>3.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/log4j/log4j -->
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.qmetry/qaf -->
<dependency>
<groupId>com.qmetry</groupId>
<artifactId>qaf</artifactId>
<version>2.1.14-RC2</version>
</dependency>
</dependencies>
</project>
After using "**mvn clean install**" shows below error :
it seems the error is related with maven with surefire plugin:
Can you please help me on this?
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< Wanderly:WanderlyScenarios >---------------------
[INFO] Building WanderlyScenarios 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom (3.9 kB at 1.5 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom (13 kB at 24 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar (25 kB at 38 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.pom (5.8 kB at 11 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.jar (34 kB at 44 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom (6.4 kB at 15 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.jar (27 kB at 48 kB/s)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # WanderlyScenarios ---
Downloading from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.pom (4.1 kB at 10 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/sonatype/spice/spice-parent/16/spice-parent-16.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/sonatype/spice/spice-parent/16/spice-parent-16.pom (8.4 kB at 19 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/sonatype/forge/forge-parent/5/forge-parent-5.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/sonatype/forge/forge-parent/5/forge-parent-5.pom (8.4 kB at 19 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.jar (226 kB at 181 kB/s)
[INFO] Deleting E:\Study Material\Selenium\WanderlyScenarios - NormalFW\target
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory E:\Study Material\Selenium\WanderlyScenarios - NormalFW\src\main\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory E:\Study Material\Selenium\WanderlyScenarios - NormalFW\src\test\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-surefire-plugin:2.18.1:test (default-test) # WanderlyScenarios ---
[INFO] No tests to run.
[INFO] Surefire report directory: E:\Study Material\Selenium\WanderlyScenarios - NormalFW\target\surefire-reports
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running TestSuite
Results :
Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:11 min
[INFO] Finished at: 2019-03-07T11:16:08+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test (default-test) on project WanderlyScenarios: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test failed: There was an error in the forked process
[ERROR] org.testng.TestNGException:
[ERROR] Cannot find class in classpath: com.scenarios.Wanderly_ApplyJob_Scenario
[ERROR] at org.testng.xml.XmlClass.loadClass(XmlClass.java:81)
[ERROR] at org.testng.xml.XmlClass.init(XmlClass.java:73)
[ERROR] at org.testng.xml.XmlClass.<init>(XmlClass.java:59)
[ERROR] at org.testng.xml.TestNGContentHandler.startElement(TestNGContentHandler.java:546)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:182)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1339)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2784)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:842)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:771)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:327)
[ERROR] at javax.xml.parsers.SAXParser.parse(SAXParser.java:195)
[ERROR] at org.testng.xml.XMLParser.parse(XMLParser.java:38)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:16)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:9)
[ERROR] at org.testng.xml.Parser.parse(Parser.java:172)
[ERROR] at org.testng.TestNG.initializeSuitesAndJarFile(TestNG.java:300)
[ERROR] at org.testng.TestNG.run(TestNG.java:1021)
[ERROR] at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:295)
[ERROR] at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:84)
[ERROR] at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:90)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException
Even when I am using "mvn compile test", its working for me locally. Even when I am trying to run inside eclispe then also it works properly*

installing 3rd party JARs

I have a maven project in Eclipse called TdkUtils, with this pom.xml:
This is a utils project. So I want to create a jar, put it in the repository and use it in another projects.
...
<groupId>com.tdk</groupId>
<artifactId>tdkUtils</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>tdkUtils</name>
...
But I got these errors when installing the plugin:
MacBook-Pro-de-nunito:tdkUtils nunito$ mvn install:install-file -Dfile=target/tdkUtils-0.0.1-SNAPSHOT.jar
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building tdkUtils 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.4:install-file (default-cli) # tdkUtils ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.353 s
[INFO] Finished at: 2017-09-18T11:29:58+02:00
[INFO] Final Memory: 9M/309M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-install-plugin:2.4:install-file (default-cli) on project tdkUtils: The artifact information is incomplete or not valid:
[ERROR] [0] 'groupId' is missing.
[ERROR] [1] 'artifactId' is missing.
[ERROR] [2] 'packaging' is missing.
[ERROR] [3] 'version' is missing.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
If you just execute mvn install while inside the same directory with the util pom.xml file, maven will install the jar file into local repository for the user.
After that, the jar file can be used by the same user from other projects.
you can install a jar to local repo without pom.xml like this:
mvn install:install-file -Dfile=target/tdkUtils-0.0.1-SNAPSHOT.jar -DgroupId=com.tdk -DartifactId=tdkUtils -Dversion=0.0.1-SNAPSHOT -Dpackaging=jar

Maven Play Framework 1.3.0-RC3 upgrade

I've a Play Framework 1.2.7 project which is managed by Maven. Now I am trying to upgrade to Play Framework version 1.3.0
What am I doing the way, how to properly upgrade from Play framework 1.2 to 1.3?
Maven play plugin in the current pom.xml
<parent>
<groupId>com.google.code.maven-play-plugin</groupId>
<artifactId>play-app-default-parent</artifactId>
<version>1.0.0-beta7</version>
</parent>
Changed play plugin to
<parent>
<groupId>com.google.code.maven-play-plugin</groupId>
<artifactId>play13-app-default-parent</artifactId>
<version>1.0.0-beta7</version>
</parent>
Maven --version
Apache Maven 3.2.3 (33f8c3e1027c3ddde99d3cdebad2656a31e8fdf4; 2014-08-12T02:58:10+06:00)
Maven home: /usr/local/Cellar/maven/3.2.3/libexec
Java version: 1.7.0_71, vendor: Oracle Corporation
Java home: /Library/Java/JavaVirtualMachines/jdk1.7.0_71.jdk/Contents/Home/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "mac os x", version: "10.10.1", arch: "x86_64", family: "mac"
mvn package clean and mvn install output
[INFO] --- maven-enforcer-plugin:1.0:enforce (enforce-maven) # gui ---
[INFO]
[INFO] --- play-maven-plugin:1.0.0-beta7:initialize (default-initialize) # gui ---
[INFO]
[INFO] --- maven-resources-plugin:2.7:resources (default-resources) # gui ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 6 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # gui ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 38 source files to /Users/sultan/project/gui/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /Users/sultan/project/gui/app/models/Dataset.java:[7,36] package javax.validation.constraints does not exist
[ERROR] /Users/sultan/project/gui/app/models/AbstractInstance.java:[14,36] package javax.validation.constraints does not exist
[ERROR] /Users/sultan/project/gui/app/models/User.java:[10,36] package javax.validation.constraints does not exist
[ERROR] /Users/sultan/project/gui/app/models/Experiment.java:[19,36] package javax.validation.constraints does not exist
[ERROR] /Users/sultan/project/gui/app/models/AccessGroup.java:[7,36] package javax.validation.constraints does not exist
[INFO] 27 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 02:16 min
[INFO] Finished at: 2015-01-15T14:45:00+06:00
[INFO] Final Memory: 26M/119M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project gui: Compilation failure: Compilation failure:
[ERROR] /Users/sultan/project/gui/app/models/AbstractInstance.java:[29,6] cannot find symbol
[ERROR] symbol: class NotNull
[ERROR] location: class models.AbstractInstance
[ERROR] /Users/sultan/project/gui/app/models/User.java:[40,6] cannot find symbol
[ERROR] symbol: class NotNull
[ERROR] location: class models.User
[ERROR] /Users/sultan/project/gui/app/models/Experiment.java:[30,6] cannot find symbol
[ERROR] symbol: class NotNull
[ERROR] location: class models.Experiment
[ERROR] /Users/sultan/project/gui/app/models/Experiment.java:[49,6] cannot find symbol
[ERROR] symbol: class NotNull
[ERROR] location: class models.Experiment
[ERROR] symbol: class ConstraintViolationException
[ERROR] location: class controllers.ExperimentController
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
I have tried to upgrade Hibernate but it didn't help
Check if you have marked any dependency as a runtime dependency. Try changing the scope to compile.
play13-app-default-parent:1.0.0-beta7 depends on play 1.3.0-RC1. This version of Play! does not contain validation-api in it's dependencies, it was added in 1.3.0-RC2 but neither 1.3.0-RC2 nor 1.3.0-RC3 were deployed to Maven central. 1.3.0 was deployed.
Next version of play13-app-default-parent will depend on 1.3.0.
For now you have to add one project property to switch to 1.3.0:
<properties>
...
<play.version>1.3.0</play.version>
</properties>

Categories

Resources