|
|
|
Re: Initial setup problems [message #579325 is a reply to message #579300] |
Thu, 20 January 2005 23:26 |
Scott Lewis Messages: 1038 Registered: July 2009 |
Senior Member |
|
|
Hi Ken,
This smells like something wrong with the Mac OS X impl of the JUnit
Plugin Test (perhaps specific to 3.1M4). Obviously, this is not what I
see running the 3.1M4 on win2k or winxp.
Bad extension specification...hmmm...I'll see if I can figure out what's
going on...maybe this is something wrong with the extension
loading/handling. Please let everyone know if you find something about
this issue on Eclipse.org.
Thanks,
Scott
Ken Gilmer wrote:
>
> Hey Scott,
>
> Thanks for your help. Yeah, I tried that as well. When I run the
> "JUnit Plug-in Test" on AllTests.java, I get the following console
> output. I am using OS X.
> Thanks
> ken
>
> "Error: " java.lang.IllegalArgumentException: No ClassLoader found for
> testplugin: org.eclipse.ecf.test
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
>
>
> Scott Lewis wrote:
>
>> Hi Ken/all,
>
>
>> Ken Gilmer wrote:
>>
>>> Hello All!
>>>
>>> I am just getting started evaluating ECF and have done the initial
>>> checkout of code. When I run the JUnit test suite I get this error
>>> on the testCreateSharedObject test. Sure enough
>>> org.eclipse.ecf.provider.generic.Client does not exist in my source
>>> tree. Running AllTest produces errors for all tests of a similiar
>>> nature. I used the PSF file to import the source into 3.1M4 today.
>>> Are there additional resources required?
>
>
>> I think that the problem is just that you need to run these tests via
>> the Eclipse 'JUnit Plugin-Test' from the Run/Debug rather than the
>> plain 'ol 'JUnit Test'. This just runs the JUnit tests with a
>> different (eclipse runtime) context.
>
>
>> The reason for this is that the JUnit Plugin-Test creates a whole new
>> workspace, and initializes all the plugins in that workspace. The ECF
>> SharedObjectContainerFactory is initialized by the OSGI plugin loading
>> process (since other plugins implement the containerFactory extension
>> point), and so it doesn't get initialized when run as a simple JUnit
>> test.
>
>
>> If this doesn't help please let all know.
>
>
>> Scott
>
>
>>>
>>> TIA,
>>> Ken Gilmer
>>>
>>>
>>> org.eclipse.ecf.core.SharedObjectContainerInstantiationExcep tion:
>>> SharedObjectContainerDescription named
>>> 'org.eclipse.ecf.provider.generic.Client' not found
>>> at
>
> org.eclipse.ecf.core.SharedObjectContainerFactory.getDescrip tionByName(SharedObjectContainerFactory.java:131)
>
>
>>>
>>> at
>
> org.eclipse.ecf.core.SharedObjectContainerFactory.makeShared ObjectContainer(SharedObjectContainerFactory.java:217)
>
>
>>>
>>> at
>
> org.eclipse.ecf.test.CreateSharedObjectTest.testCreateShared Object(CreateSharedObjectTest.java:36)
>
>
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
>
>
>>>
>>> at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
>
>
>>>
>>> at java.lang.reflect.Method.invoke(Method.java:324)
>>> at junit.framework.TestCase.runTest(TestCase.java:154)
>>> at junit.framework.TestCase.runBare(TestCase.java:127)
>>> at junit.framework.TestResult$1.protect(TestResult.java:106)
>>> at junit.framework.TestResult.runProtected(TestResult.java:124)
>>> at junit.framework.TestResult.run(TestResult.java:109)
>>> at junit.framework.TestCase.run(TestCase.java:118)
>>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>> at
>
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTe sts(RemoteTestRunner.java:474)
>
>
>>>
>>> at
>
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(R emoteTestRunner.java:342)
>
>
>>>
>>> at
>
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main( RemoteTestRunner.java:194)
>
>
>>>
>>>
>>>
>>>
>
|
|
|
Re: Initial setup problems [message #579343 is a reply to message #579300] |
Fri, 21 January 2005 10:23 |
|
ken, scott,
the reason for this behaviour is (without looking at the code),
that the test plugin declares an extension for the org.eclipse.ui.startup
extension point. this extension will start/initialize the plugin even
if it is not used at once. a class is specified there that implements
the IStartup interface.
most probably the name of the plugin class is given there,
but the class does NOT implement the IStartup interface.
when the eclipse ui plugin reads its extensions, it tries to
instantiate the plugin class, cast it to IStartup - and fails!
failing during startup means, that the plugin classloader is NOT
initialized! subsequent calls into the plugin's code will end
in NoClassLoaderFound or ClassNotFound exceptions.
you should implement IStartup (due to a bug in the eclipse startup
sequence preferably NOT the plugin class) and leave the earlyStartup()
method EMPTY! initialization code should go into start(...) or startup(...),
the presence of IStartup/earlyStartup() is enough to make the normal
plugin startup happen (with calls to start(...) and startup(...)).
hope this helps ;-)
cheers
/eike
Ken Gilmer wrote:
>
> Hey Scott,
>
> Thanks for your help. Yeah, I tried that as well. When I run the
> "JUnit Plug-in Test" on AllTests.java, I get the following console
> output. I am using OS X.
> Thanks
> ken
>
> "Error: " java.lang.IllegalArgumentException: No ClassLoader found for
> testplugin: org.eclipse.ecf.test
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Unhandled Exception
> Reason:
> Unable to execute early startup code for an extension
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
> Bad extension specification
> Reason:
> startup class must implement org.eclipse.ui.IStartup
>
>
> Scott Lewis wrote:
>
>> Hi Ken/all,
>
>
>> Ken Gilmer wrote:
>>
>>> Hello All!
>>>
>>> I am just getting started evaluating ECF and have done the initial
>>> checkout of code. When I run the JUnit test suite I get this error
>>> on the testCreateSharedObject test. Sure enough
>>> org.eclipse.ecf.provider.generic.Client does not exist in my source
>>> tree. Running AllTest produces errors for all tests of a similiar
>>> nature. I used the PSF file to import the source into 3.1M4 today.
>>> Are there additional resources required?
>
>
>> I think that the problem is just that you need to run these tests via
>> the Eclipse 'JUnit Plugin-Test' from the Run/Debug rather than the
>> plain 'ol 'JUnit Test'. This just runs the JUnit tests with a
>> different (eclipse runtime) context.
>
>
>> The reason for this is that the JUnit Plugin-Test creates a whole new
>> workspace, and initializes all the plugins in that workspace. The ECF
>> SharedObjectContainerFactory is initialized by the OSGI plugin loading
>> process (since other plugins implement the containerFactory extension
>> point), and so it doesn't get initialized when run as a simple JUnit
>> test.
>
>
>> If this doesn't help please let all know.
>
>
>> Scott
>
>
>>>
>>> TIA,
>>> Ken Gilmer
>>>
>>>
>>> org.eclipse.ecf.core.SharedObjectContainerInstantiationExcep tion:
>>> SharedObjectContainerDescription named
>>> 'org.eclipse.ecf.provider.generic.Client' not found
>>> at
>
> org.eclipse.ecf.core.SharedObjectContainerFactory.getDescrip tionByName(SharedObjectContainerFactory.java:131)
>
>
>>>
>>> at
>
> org.eclipse.ecf.core.SharedObjectContainerFactory.makeShared ObjectContainer(SharedObjectContainerFactory.java:217)
>
>
>>>
>>> at
>
> org.eclipse.ecf.test.CreateSharedObjectTest.testCreateShared Object(CreateSharedObjectTest.java:36)
>
>
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
>
>
>>>
>>> at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
>
>
>>>
>>> at java.lang.reflect.Method.invoke(Method.java:324)
>>> at junit.framework.TestCase.runTest(TestCase.java:154)
>>> at junit.framework.TestCase.runBare(TestCase.java:127)
>>> at junit.framework.TestResult$1.protect(TestResult.java:106)
>>> at junit.framework.TestResult.runProtected(TestResult.java:124)
>>> at junit.framework.TestResult.run(TestResult.java:109)
>>> at junit.framework.TestCase.run(TestCase.java:118)
>>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>> at
>
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTe sts(RemoteTestRunner.java:474)
>
>
>>>
>>> at
>
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(R emoteTestRunner.java:342)
>
>
>>>
>>> at
>
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main( RemoteTestRunner.java:194)
>
>
>>>
>>>
>>>
>>>
>
Cheers
/Eike
----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
|
|
|
Powered by
FUDForum. Page generated in 0.03603 seconds