Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » SWTBot OSGi trouble...(my osgi does not init bundle .swtbot..headless...)
SWTBot OSGi trouble... [message #707047] Mon, 01 August 2011 07:06
Bernhard Anzeletti is currently offline Bernhard AnzelettiFriend
Messages: 14
Registered: July 2011
Location: Austria
Junior Member
Dear friends of RCP,

Currently I am trying to get SWTBot headless tests running using my Windows7 / Indigo / x86 (32bit) installation. I have a nice .cmd file (which can actually start my product in the target), but when I try with swtbottestapplication, things go terribly awry. The clue seems to be that the headless plugin asks for import package org.eclipse.ui (NOT Required Bundle), which osgi obviously does not want to provide.
Any help highly appreciated.

Additional Info
When I keep the framework running and query the eclipse.ui bundle status, it is "LAZY" in the first place. When I manually activate it, it gets "ACTIVATED", but I still cannot activate the swtbot.headless plugin because of the missing package import. Looks as if I had to declare some additional "friendship" relations... or is this wrong kind of thinking?

Further question: simpleconfigurator
Examining the standard config.ini files, I came across a "simpleconfigurator". I suppose this is a vehicle for installing all bundles in a specific directory (kind of). Am I right?

Kind regards,
Bernhard


Start Command
C:\ANBInstall\Sun\jdk32_6_23\bin\java ^
-Xms256m -Xmx768m -XX:MaxPermSize=512m ^
-classpath c:\ANBWork\ANBERNCommander.wip\test\eclipse\plugins\org.eclipse.equinox.launcher_1.2.0.v20110502.jar ^
org.eclipse.core.launcher.Main ^
-install C:/ANBWork/ANBERNCommander.wip/test/eclipse ^
-application org.eclipse.swtbot.eclipse.junit4.headless.swtbottestapplication ^
-testApplication com.anbern.commander.application ^
-product com.anbern.commander.product ^
-data C:/ANBWork/ANBERNCommander.wip/test/workspace ^
formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,C:/ANBWork/ANBERNCommander.wip/test/result/TestResult.xml ^
-testPluginName com.anbern.commander.test ^
-className com.anbern.commander.test.CommanderUITest ^
-arch x86 ^
-debug ^
-consoleLog


Config.ini
(located in eclipse/configuration)
#Product Runtime Configuration File
osgi.bundles.defaultStartLevel=4
osgi.install.area=C:\ANBWork\ANBERNCommander.wip\test\eclipse
osgi.bundles=com.anbern.commander,\
  com.ibm.icu,\
  org.eclipse.core.commands,\
  org.eclipse.core.contenttype,\
  org.eclipse.core.databinding,\
  org.eclipse.core.databinding.beans,\
  org.eclipse.core.databinding.observable,\
  org.eclipse.core.databinding.property,\
  org.eclipse.core.expressions,\
  org.eclipse.core.jobs,\
  org.eclipse.core.runtime@start,\
  org.eclipse.core.runtime.compatibility.auth,\
  org.eclipse.equinox.common@2:start,\
  org.eclipse.equinox.preferences,\
  org.eclipse.equinox.registry,\
  org.eclipse.equinox.app,\
  org.eclipse.equinox.ds,\
  org.eclipse.equinox.launcher,\
  org.eclipse.equinox.simpleconfigurator,\
  org.eclipse.equinox.util,\
  org.eclipse.rcp,\
  org.eclipse.update.configurator,\
  org.eclipse.jface,\
  org.eclipse.jface.databinding,\
  org.eclipse.osgi.services,\
  org.eclipse.swt,\
  org.eclipse.swt.win32.win32.x86,\
  org.eclipse.ui,\
  org.eclipse.ui.workbench,\
  org.eclipse.help,\
  org.eclipse.core.runtime.compatibility,\
  org.apache.log4j,\
  org.hamcrest,\
  org.hamcrest.text,\
  org.hamcrest.library,\
  org.hamcrest.integration,\
  org.hamcrest.core,\
  org.apache.ant,\
  org.junit,\
  org.junit4,\
  org.eclipse.jdt.junit.runtime,\
  org.eclipse.swtbot.swt.finder,\
  org.eclipse.swtbot.junit4_x,\
  org.eclipse.swtbot.eclipse.finder,\
  org.eclipse.swtbot.eclipse.core,\
  org.eclipse.swtbot.ant.optional.junit4,\
  org.eclipse.swtbot.eclipse.junit4.headless


Result
Sadly, when I run all this I receive:
!ENTRY org.eclipse.osgi 2 0 2011-07-29 16:54:55.249
!MESSAGE One or more bundles are not resolved because the following root constraints are not resolved:
!SUBENTRY 1 org.eclipse.osgi 2 0 2011-07-29 16:54:55.249
!MESSAGE Bundle initial@reference:file:plugins/org.eclipse.swtbot.eclipse.junit4.headless_2.0.4.20110304_0338-e5aff47-dev-e36/ was not resolved.
!SUBENTRY 2 org.eclipse.swtbot.eclipse.junit4.headless 2 0 2011-07-29 16:54:55.249
!MESSAGE Missing imported package org.eclipse.ui_0.0.0.

!ENTRY org.eclipse.osgi 2 0 2011-07-29 16:54:55.265
!MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists:
!SUBENTRY 1 org.eclipse.osgi 2 0 2011-07-29 16:54:55.265
!MESSAGE Bundle org.eclipse.swtbot.eclipse.junit4.headless_2.0.4.20110304_0338-e5aff47-dev-e36 [141] was not resolved.
!SUBENTRY 2 org.eclipse.swtbot.eclipse.junit4.headless 2 0 2011-07-29 16:54:55.265
!MESSAGE Missing imported package org.eclipse.ui_0.0.0.

!ENTRY org.eclipse.osgi 4 0 2011-07-29 16:54:55.265
!MESSAGE Application error
!STACK 1
java.lang.RuntimeException: Application "org.eclipse.swtbot.eclipse.junit4.headless.swtbottestapplication" could not be found in the registry. The applications available are: com.anbern.commander.application, org.eclipse.equinox.app.error, org.eclipse.swtbot.eclipse.core.swtbottestapplication.
Previous Topic:update for servletbridge
Next Topic:Problem with p2 headless update with <no connection> case in eclipse 3.7
Goto Forum:
  


Current Time: Tue Dec 23 04:25:35 GMT 2014

Powered by FUDForum. Page generated in 0.01601 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software