Buggy code:
public class JMXProtocolPackager implements DeploymentPackager { private static final List < String > defaultDependencies = new ArrayList < String > ( ) ; private static final Logger log = Logger . getLogger ( JMXProtocolPackager . class ) ; private ServiceArchiveHolder archiveHolder ; JMXProtocolPackager ( ServiceArchiveHolder archiveHolder ) { } @ Override public Archive < ? > generateDeployment ( TestDeployment testDeployment , Collection < ProtocolArchiveProcessor > protocolProcessors ) { } private JavaArchive generateArquillianServiceArchive ( Collection < Archive < ? > > auxArchives ) { final JavaArchive archive = ShrinkWrap . create ( JavaArchive . class , "arquillian-service" ) ; JMXProtocolPackager . log . debugf ( "Generating:<seq2seq4repair_space>%s" , archive . getName ( ) ) ; archive . addPackage ( ArquillianService . class . getPackage ( ) ) ; archive . addPackage ( AbstractJMXProtocol . class . getPackage ( ) ) ; archive . addClasses ( ServerSetup . class , ServerSetupTask . class , ManagementClient . class , Authentication . class , NetworkUtils . class ) ; final Set < String > loadableExtensions = new HashSet < String > ( ) ; final String loadableExtensionsPath = "META-INF//services//" + ( RemoteLoadableExtension . class . getName ( ) ) ; for ( Archive < ? > aux : auxArchives ) { Node node = aux . get ( loadableExtensionsPath ) ; if ( node != null ) { BufferedReader br = new BufferedReader ( new InputStreamReader ( node . getAsset ( ) . openStream ( ) ) ) ; try { String line = br . readLine ( ) ; while ( line != null ) { loadableExtensions . add ( line ) ; line = br . readLine ( ) ; } } catch ( IOException ex ) { } } JMXProtocolPackager . log . debugf ( "Merging<seq2seq4repair_space>archive:<seq2seq4repair_space>%s" , aux ) ; archive . merge ( aux ) ; } loadableExtensions . add ( JMXProtocolEndpointExtension . class . getName ( ) ) ; loadableExtensions . add ( InContainerManagementClientExtension . class . getName ( ) ) ; archive . setManifest ( new Asset ( ) { public InputStream openStream ( ) { ManifestBuilder builder = ManifestBuilder . newInstance ( ) ; StringBuffer dependencies = new StringBuffer ( ) ; dependencies . append ( "org.jboss.as.jmx," ) ; dependencies . append ( "org.jboss.as.server," ) ; dependencies . append ( "org.jboss.as.controller-client," ) ; dependencies . append ( "org.jboss.as.osgi," ) ; dependencies . append ( "org.jboss.jandex," ) ; dependencies . append ( "org.jboss.logging," ) ; dependencies . append ( "org.jboss.modules," ) ; dependencies . append ( "org.jboss.dmr," ) ; dependencies . append ( "org.jboss.msc," ) ; dependencies . append ( "org.jboss.osgi.framework," ) ; dependencies . append ( "org.osgi.core" ) ; builder . addManifestHeader ( "Dependencies" , dependencies . toString ( ) ) ; return builder . openStream ( ) ; } } ) ; String serviceActivatorPath = "META-INF//services//" + ( ServiceActivator . class . getName ( ) ) ; final URL serviceActivatorURL = this . getClass ( ) . getClassLoader ( ) . getResource ( ( "arquillian-service//" + serviceActivatorPath ) ) ; if ( serviceActivatorURL == null ) { throw new RuntimeException ( ( ( ( "No<seq2seq4repair_space>arquillian-service//" + serviceActivatorPath ) + "<seq2seq4repair_space>found<seq2seq4repair_space>by<seq2seq4repair_space>classloader:<seq2seq4repair_space>" ) + ( this . getClass ( ) . getClassLoader ( ) ) ) ) ; } archive . addAsResource ( new UrlAsset ( serviceActivatorURL ) , serviceActivatorPath ) ; archive . addAsResource ( new Asset ( ) { public InputStream openStream ( ) { ByteArrayOutputStream baos = new ByteArrayOutputStream ( ) ; try { Properties props = new Properties ( ) ; props . setProperty ( Constants . BUNDLE_SYMBOLICNAME , "arquillian-service" ) ; StringBuilder builder = new StringBuilder ( ) ; builder . append ( "org.jboss.arquillian.container.test.api,org.jboss.arquillian.junit," ) ; builder . append ( "org.jboss.arquillian.osgi,org.jboss.arquillian.test.api," ) ; <START_BUG> builder . append ( "org.jboss.as.osgi," ) ; <END_BUG> builder . append ( "org.jboss.shrinkwrap.api,org.jboss.shrinkwrap.api.asset,org.jboss.shrinkwrap.api.spec," ) ; builder . append ( "org.junit,org.junit.runner" ) ; props . setProperty ( Constants . EXPORT_PACKAGE , builder . toString ( ) ) ; props . store ( baos , null ) ; } catch ( IOException ex ) { throw new IllegalStateException ( "Cannot<seq2seq4repair_space>write<seq2seq4repair_space>osgi<seq2seq4repair_space>metadata" , ex ) ; } return new ByteArrayInputStream ( baos . toByteArray ( ) ) ; } } , "META-INF//jbosgi-xservice.properties" ) ; archive . delete ( ArchivePaths . create ( loadableExtensionsPath ) ) ; archive . addAsResource ( new Asset ( ) { @ Override public InputStream openStream ( ) { ByteArrayOutputStream baos = new ByteArrayOutputStream ( ) ; PrintWriter pw = new PrintWriter ( new OutputStreamWriter ( baos ) ) ; for ( String line : loadableExtensions ) { pw . println ( line ) ; } pw . close ( ) ; return new ByteArrayInputStream ( baos . toByteArray ( ) ) ; } } , loadableExtensionsPath ) ; JMXProtocolPackager . log . debugf ( "Loadable<seq2seq4repair_space>extensions:<seq2seq4repair_space>%s" , loadableExtensions ) ; JMXProtocolPackager . log . tracef ( "Archive<seq2seq4repair_space>content:<seq2seq4repair_space>%s\n%s" , archive , archive . toString ( true ) ) ; return archive ; } private void addModulesManifestDependencies ( Archive < ? > appArchive ) { } }

Fix:
builder . append ( "org.jboss.as.arquillian.api,org.jboss.as.arquillian.container,org.jboss.as.osgi," ) ;