Classpath entries for Plugin unit test [message #8378] |
Wed, 25 June 2008 15:39 |
T Kruse Messages: 73 Registered: July 2009 |
Member |
|
|
Hi,
I created a plugin with JUnit tests that uses com.sun.tools.javac.Main
in the code to compile classes. Main is located in the tools.jar of my
JDK.
So in my plugin project, I set a variable to my JDKs tools.jar, and added
that variable to the build path of the project. The project builds fine.
However, when I run the Plugin JUnit test, I get this exception below.
Now I am sure there is a way I can get this to run, maybe by changing
something in the launch configuration for the Plugin test. Can anyone tell
me what to do?
java.lang.NoClassDefFoundError: com/sun/tools/javac/Main
at
test.util.ParserGenerationTestHelper.compileParser(ParserGen erationTestHelper.java:67)
...
Caused by: java.lang.ClassNotFoundException: com.sun.tools.javac.Main
at java.lang.ClassLoader.findClass(ClassLoader.java:358)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl assInternal(BundleLoader.java:429)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:369)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:357)
at
org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loa dClass(DefaultClassLoader.java:83)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
... 45 more
|
|
|
Powered by
FUDForum. Page generated in 0.04683 seconds