Home » General (non-technical) » Test » Eclipse plug-in: Invalid Activator
Eclipse plug-in: Invalid Activator [message #9263] |
Thu, 27 September 2007 10:34  |
Eclipse User |
|
|
|
Originally posted by: slider161.hotmail.com
I am writing an Ant script to run a JUnit test suite within an Eclipse
plug-in and generate a JUnit report outside of Eclipse. I am referring to
this tutorial http://dev.eclipse.org/viewcvs/index.cg ... ision=1.4. I
have written a test.xml file for my plug-in
which uses the org.eclipse.test library.xml file run the suite and
generate a report.
I am getting an error "org.osgi.framework.BundleException: The activator
com.propylon.core.tests.Activator for bundle com.propylon.core.Test is
invalid"
I have checked that all the require plug-ins are loaded in eclipse.
The Activator class autmatically generated when i created the plug-in,
yet it seems ok.
the manifest file seem to be correct.
Are there any other common causes for this error, and what are they?
Below is my Activator class.
Code:
package com.propylon.core.tests;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.osgi.framework.BundleContext;
/**
* The activator class controls the plug-in life cycle
*/
public class Activator extends AbstractUIPlugin {
// The plug-in ID
public static final String PLUGIN_ID = "com.propylon.core.tests";
// The shared instance
private static Activator plugin;
/**
* The constructor
*/
public Activator() {
}
/*
* (non-Javadoc)
* @see
org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framew ork.BundleContext)
*/
public void start(BundleContext context) throws Exception {
super.start(context);
plugin = this;
}
/*
* (non-Javadoc)
* @see
org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framewo rk.BundleContext)
*/
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
}
/**
* Returns the shared instance
*
* @return the shared instance
*/
public static Activator getDefault() {
return plugin;
}
}
Below is the Manifest file
Code:
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: TestsPlug-in
Bundle-SymbolicName: com.propylon.core.Test;singleton:=true
Bundle-Version: 1.0.0
Bundle-Activator: com.propylon.core.tests.Activator
Bundle-Vendor: PROPYLON
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
com.propylon.core.repository,
org.eclipse.core.resources,
org.tmatesoft.svnkit,
org.eclipse.ui.navigator,
org.junit
Eclipse-LazyStart: true
Bundle-ClassPath: junit.plugin.jar,
.
Export-Package: com,
com.propylon,
com.propylon.core,
com.propylon.core.tests,
com.propylon.core.tests.testcase,
com.propylon.core.tests.testsuite,
org.eclipse.tptp.test.tools.junit.plugin.internal;x-internal :=true,
org.eclipse.tptp.test.tools.junit.plugin.internal.harness;x- internal:=true,
org.eclipse.tptp.test.tools.junit.plugin.internal.launch;x-i nternal:=true,
org.eclipse.tptp.test.tools.junit.plugin.internal.modelsync; x-internal:=true,
org.eclipse.tptp.test.tools.junit.plugin.internal.resources; x-internal:=true,
org.eclipse.tptp.test.tools.junit.plugin.internal.util;x-int ernal:=true,
org.eclipse.tptp.test.tools.junit.plugin.util
Are there any obvious flawes with my code that my be causing the problem?
thank you for your time.
slider
P.S. I am new to this newsgroup, and apologise if this post is in the
wrong forum.
|
|
|
Re: Eclipse plug-in: Invalid Activator [message #9286 is a reply to message #9263] |
Thu, 27 September 2007 11:19   |
Eclipse User |
|
|
|
Originally posted by: merks.ca.ibm.com
Slider,
No one answers questions here. This newsgroup is just for testing
whether you can properly post to an Eclipse newsgroup. You should post
to the platform newsgroup. Does it make sense that you have a UI
Plugin? If Ant is running without a UI that probably won't work.
slider161 wrote:
> I am writing an Ant script to run a JUnit test suite within an Eclipse
> plug-in and generate a JUnit report outside of Eclipse. I am referring
> to this tutorial http://dev.eclipse.org/viewcvs/index.cg ...
> ision=1.4. I have written a test.xml file for my plug-in
> which uses the org.eclipse.test library.xml file run the suite and
> generate a report.
>
> I am getting an error "org.osgi.framework.BundleException: The
> activator com.propylon.core.tests.Activator for bundle
> com.propylon.core.Test is invalid"
> I have checked that all the require plug-ins are loaded in eclipse.
> The Activator class autmatically generated when i created the plug-in,
> yet it seems ok.
> the manifest file seem to be correct.
>
> Are there any other common causes for this error, and what are they?
> Below is my Activator class.
>
> Code:
>
>
> package com.propylon.core.tests;
>
> import org.eclipse.ui.plugin.AbstractUIPlugin;
> import org.osgi.framework.BundleContext;
>
> /**
> * The activator class controls the plug-in life cycle
> */
> public class Activator extends AbstractUIPlugin {
>
> // The plug-in ID
> public static final String PLUGIN_ID = "com.propylon.core.tests";
>
> // The shared instance
> private static Activator plugin;
> /**
> * The constructor
> */
> public Activator() {
> }
>
> /*
> * (non-Javadoc)
> * @see
> org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framew ork.BundleContext)
>
> */
> public void start(BundleContext context) throws Exception {
> super.start(context);
> plugin = this;
> }
>
> /*
> * (non-Javadoc)
> * @see
> org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framewo rk.BundleContext)
>
> */
> public void stop(BundleContext context) throws Exception {
> plugin = null;
> super.stop(context);
> }
>
> /**
> * Returns the shared instance
> *
> * @return the shared instance
> */
> public static Activator getDefault() {
> return plugin;
> }
>
> }
>
>
>
> Below is the Manifest file
>
> Code:
>
>
> Manifest-Version: 1.0
> Bundle-ManifestVersion: 2
> Bundle-Name: TestsPlug-in
> Bundle-SymbolicName: com.propylon.core.Test;singleton:=true
> Bundle-Version: 1.0.0
> Bundle-Activator: com.propylon.core.tests.Activator
> Bundle-Vendor: PROPYLON
> Require-Bundle: org.eclipse.ui,
> org.eclipse.core.runtime,
> com.propylon.core.repository,
> org.eclipse.core.resources,
> org.tmatesoft.svnkit,
> org.eclipse.ui.navigator,
> org.junit
> Eclipse-LazyStart: true
> Bundle-ClassPath: junit.plugin.jar,
> .
> Export-Package: com,
> com.propylon,
> com.propylon.core,
> com.propylon.core.tests,
> com.propylon.core.tests.testcase,
> com.propylon.core.tests.testsuite,
> org.eclipse.tptp.test.tools.junit.plugin.internal;x-internal :=true,
> org.eclipse.tptp.test.tools.junit.plugin.internal.harness;x- internal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.launch;x-i nternal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.modelsync; x-internal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.resources; x-internal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.util;x-int ernal:=true,
> org.eclipse.tptp.test.tools.junit.plugin.util
>
> Are there any obvious flawes with my code that my be causing the problem?
>
> thank you for your time.
>
> slider
>
> P.S. I am new to this newsgroup, and apologise if this post is in the
> wrong forum.
>
|
|
| |
Re: Eclipse plug-in: Invalid Activator [message #561417 is a reply to message #9263] |
Thu, 27 September 2007 11:19  |
Eclipse User |
|
|
|
Slider,
No one answers questions here. This newsgroup is just for testing
whether you can properly post to an Eclipse newsgroup. You should post
to the platform newsgroup. Does it make sense that you have a UI
Plugin? If Ant is running without a UI that probably won't work.
slider161 wrote:
> I am writing an Ant script to run a JUnit test suite within an Eclipse
> plug-in and generate a JUnit report outside of Eclipse. I am referring
> to this tutorial http://dev.eclipse.org/viewcvs/index.cg ...
> ision=1.4. I have written a test.xml file for my plug-in
> which uses the org.eclipse.test library.xml file run the suite and
> generate a report.
>
> I am getting an error "org.osgi.framework.BundleException: The
> activator com.propylon.core.tests.Activator for bundle
> com.propylon.core.Test is invalid"
> I have checked that all the require plug-ins are loaded in eclipse.
> The Activator class autmatically generated when i created the plug-in,
> yet it seems ok.
> the manifest file seem to be correct.
>
> Are there any other common causes for this error, and what are they?
> Below is my Activator class.
>
> Code:
>
>
> package com.propylon.core.tests;
>
> import org.eclipse.ui.plugin.AbstractUIPlugin;
> import org.osgi.framework.BundleContext;
>
> /**
> * The activator class controls the plug-in life cycle
> */
> public class Activator extends AbstractUIPlugin {
>
> // The plug-in ID
> public static final String PLUGIN_ID = "com.propylon.core.tests";
>
> // The shared instance
> private static Activator plugin;
> /**
> * The constructor
> */
> public Activator() {
> }
>
> /*
> * (non-Javadoc)
> * @see
> org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framew ork.BundleContext)
>
> */
> public void start(BundleContext context) throws Exception {
> super.start(context);
> plugin = this;
> }
>
> /*
> * (non-Javadoc)
> * @see
> org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framewo rk.BundleContext)
>
> */
> public void stop(BundleContext context) throws Exception {
> plugin = null;
> super.stop(context);
> }
>
> /**
> * Returns the shared instance
> *
> * @return the shared instance
> */
> public static Activator getDefault() {
> return plugin;
> }
>
> }
>
>
>
> Below is the Manifest file
>
> Code:
>
>
> Manifest-Version: 1.0
> Bundle-ManifestVersion: 2
> Bundle-Name: TestsPlug-in
> Bundle-SymbolicName: com.propylon.core.Test;singleton:=true
> Bundle-Version: 1.0.0
> Bundle-Activator: com.propylon.core.tests.Activator
> Bundle-Vendor: PROPYLON
> Require-Bundle: org.eclipse.ui,
> org.eclipse.core.runtime,
> com.propylon.core.repository,
> org.eclipse.core.resources,
> org.tmatesoft.svnkit,
> org.eclipse.ui.navigator,
> org.junit
> Eclipse-LazyStart: true
> Bundle-ClassPath: junit.plugin.jar,
> .
> Export-Package: com,
> com.propylon,
> com.propylon.core,
> com.propylon.core.tests,
> com.propylon.core.tests.testcase,
> com.propylon.core.tests.testsuite,
> org.eclipse.tptp.test.tools.junit.plugin.internal;x-internal :=true,
> org.eclipse.tptp.test.tools.junit.plugin.internal.harness;x- internal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.launch;x-i nternal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.modelsync; x-internal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.resources; x-internal:=true,
>
> org.eclipse.tptp.test.tools.junit.plugin.internal.util;x-int ernal:=true,
> org.eclipse.tptp.test.tools.junit.plugin.util
>
> Are there any obvious flawes with my code that my be causing the problem?
>
> thank you for your time.
>
> slider
>
> P.S. I am new to this newsgroup, and apologise if this post is in the
> wrong forum.
>
|
|
| |
Goto Forum:
Current Time: Fri May 09 03:42:04 EDT 2025
Powered by FUDForum. Page generated in 0.05513 seconds
|