Re: Could not run main class in src/test/java due to ClassNotFoundException

2018-07-13 Thread Baha Baniya
Thank you for the Response, Tommy. I already had a classpathScope test as shown in baha_baniya / exec-maven-plugin-sample / source / pom.xml — Bitbucket. | | | | baha_baniya / exec-maven-plugin-sample / source / pom.xml — Bitbucket | | | Just figured out - I have to run class

Re: Could not run main class in src/test/java due to ClassNotFoundException

2018-07-12 Thread Tommy Svensson
Hello Baha, You need a dependency to a jar containing the `np.com.bahadur.ExecTest` class. According to: https://www.mojohaus.org/exec-maven-plugin/java-mojo.html the dependency should have scope ’runtime’ unless you set the ’classpathScope’ parameter to something else.  Your pom has no

Could not run main class in src/test/java due to ClassNotFoundException

2018-07-12 Thread Baha Baniya
Hi When I run mvn exec:java :  I get error: java.lang.ClassNotFoundException: np.com.bahadur.ExecTest    at java.net.URLClassLoader.findClass (URLClassLoader.java:381)    at java.lang.ClassLoader.loadClass (ClassLoader.java:424)    at java.lang.ClassLoader.loadClass (ClassLoader.java:357)    at