Here is the test case I wrote yesterday:

public classJavaConfigurationProviderIT {

    @Test
    public voidbla() {
        JavaArchive roundtrip = ShrinkWrap.create(JavaArchive.class)
            .addAsServiceProvider(PropertySource.class, MPS.class);

        ClassLoader parent = Thread.currentThread().getContextClassLoader();
        ShrinkWrapClassLoader swcl =newShrinkWrapClassLoader(roundtrip);

        Thread.currentThread().setContextClassLoader(swcl);


        for(PropertySource propertySource : 
ServiceLoader.load(PropertySource.class)) {
            System.out.println("*****");
            System.out.println(propertySource.getName());
        }

        System.out.println(roundtrip.toString(true));
    }

    public static  classMPSimplementsPropertySource {}
}



Am 29.01.15 um 09:27 schrieb Oliver B. Fischer:
But even with Arquillian we would need ShrinkWrap to build deployable artifacts. Or what do you mean? For SE we need only to tweak our class path or class loader.

Bye,

Oliver

Am 29.01.15 um 08:31 schrieb Mark Struberg:
That's why I wanted some 'isolating' Arquillian SE adaptor :)
I prefer using Arquillian over any homegrown solution as we might use that to later test EE containers as well.

LieGrue,
strub






--
N Oliver B. Fischer
A Schönhauser Allee 64, 10437 Berlin, Deutschland/Germany
P +49 30 44793251
M +49 178 7903538
E [email protected]
S oliver.b.fischer
J [email protected]
X http://xing.to/obf

Reply via email to