Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3
Include Page
FELIX:apache-felix-ipojo-headerFELIX:
apache-felix-ipojo-header

...

This page describes how using the junit4osgi framework. With the archive tutorial, a pre-configured version of Felix (with the test framework already installed) is also provided.

Div
classtoc
Table of Contents
maxLevel4
minLevel2

...

Getting JUnit4OSGi

The JUnit4OSGi framework is available from the Felix downloads. Source code is also available in the iPOJO subproject sub-project (sources). The JUnit4OSGi framework and the different launchers are built when you compile Felix.

...

  • org.apache.felix.ipojo-1.26.0.jar: iPOJO Core bundle
  • org.apache.felix.ipojo.handler.extender-1.26.0.jar: iPOJO Extender pattern handler
  • org.apache.felix.ipojo.junit4osgi-1.1.0-SNAPSHOT.jar: the JUnit4OSGi framework
  • org.apache.felix.ipojo.junit4osgi.felix-command-1.1.0-SNAPSHOT.jar: the command line junit4osgi runner

...

So now you know everything required to run test inside OSGi. You can start developing your own test. To help you a little bit, junit4osgi provides utilities methods greatly reducing the amount of code to write in your tests. Moreover, if you're a Maven user, the maven-junit4osgi-plugin is made for you. It just run runs your test directly during the maven build process.

Include Page
FELIX:apache-felix-ipojo-footerFELIX:
apache-felix-ipojo-footer