Not found Junit Test Case [message #14168] |
Thu, 15 January 2009 06:17  |
Eclipse User |
|
|
|
Hello,
I am trying to test a eclipse plugin with SWTbot, but I having problems.
1)I added the plugins necessary for SWTbot.
2)I created a plug-in project in Eclipse and added my Junit Test case.
3)I configured my classpath and run this class like junit3 (Test runner)
4) Finally, I run a product like org.eclipse.sdk.ide
The result is:
Class not found eee.FooTest
java.lang.ClassNotFoundException: eee.FooTest
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl assInternal(BundleLoader.java:481)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:397)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:385)
at
org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loa dClass(DefaultClassLoader.java:87)
at java.lang.ClassLoader.loadClass(Unknown Source)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.loadCl ass(BundleLoader.java:313)
at
org.eclipse.osgi.framework.internal.core.BundleHost.loadClas s(BundleHost.java:227)
at
org.eclipse.osgi.framework.internal.core.AbstractBundle.load Class(AbstractBundle.java:1274)
at
org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunne r$BundleClassLoader.findClass(RemotePluginTestRunner.java:38 )
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.loadC lass(RemoteTestRunner.java:683)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.loadC lasses(RemoteTestRunner.java:425)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTe sts(RemoteTestRunner.java:445)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTe sts(RemoteTestRunner.java:673)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(R emoteTestRunner.java:386)
at
org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunne r.main(RemotePluginTestRunner.java:62)
at
net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplic ation.java:122)
at
org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(Work benchTestable.java:68)
at java.lang.Thread.run(Unknown Source)
Can someone help me??
Thanks and regards.
|
|
|
|
|
|
|
Re: Not found Junit Test Case [message #14288 is a reply to message #14272] |
Thu, 15 January 2009 11:05   |
Eclipse User |
|
|
|
It does not matter where your workspace is located.
In order that tests are repeatable, and reproducible every time, it is
generally the case that you clear your workspace.
If you need some projects or some workspace settings that you need in
your workspace, you may import them as part of your test setup.
-- Ketan
On 15/1/09 20:49, Luis Miguel wrote:
> Hi,
> If you look the part of tutorial: "Executing SWTBot Tests for Eclipse
> Plugins", when we select the application that I want to test,there are
> three parts that we must configure: Workspace data, Program to run and
> Java Runtime Environment. The first (Workspace data), we select
> "${workspace_loc}/../junit-workspace" or we select a new workspace? Is
> this important?
>
> Thanks and regards
>
> Luis Miguel
>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Re: Not found Junit Test Case [message #16408 is a reply to message #16401] |
Tue, 20 January 2009 12:09  |
Eclipse User |
|
|
|
Oops, I'd meant SWTBotEclipseTestCase.
If things do not work, please file a bug at bugs.eclipse.org and attach
the complete log file (compress it please)
-- Ketan
On 20/1/09 22:34, Luis Miguel wrote:
> Hi,
> If I extend from SWTBotTestCase class, I need import
> net.sf.swtbot.SWTBotTestCase and the last version is
> net.sf.swtbot-2.0.0.1164-dev. In addition, if I extend from
> SWTBotTestCase, the action bot.view ("Welcome").close() does not work.
>
|
|
|
Powered by
FUDForum. Page generated in 0.05995 seconds