Package org.rioproject.test.simple

Examples of org.rioproject.test.simple.Simple


                                 "resources"+File.separator+
                                 "opstring"+File.separator+
                                 "logging_simple_opstring.groovy");
        Assert.assertNotNull(opstring);
        testManager.deploy(opstring);
        Simple simple = (Simple)testManager.waitForService(Simple.class);
        Assert.assertNotNull(simple);

        Entry[] attrs = new Entry[]{ServiceLogEvent.getEventDescriptor()};
        ServiceTemplate template = new ServiceTemplate(null, null, attrs);
        ServiceItem[] items = testManager.getServiceDiscoveryManager().lookup(template, Integer.MAX_VALUE, null);
View Full Code Here


                                 "opstring"+File.separator+
                                 "logging_simple_forked_opstring.groovy");
        Assert.assertNotNull(opstring);
        OperationalStringManager mgr = testManager.deploy(opstring);
        testManager.waitForDeployment(mgr);
        Simple simple = (Simple)testManager.waitForService(Simple.class, "Simple Logging Forked Simon");
        Assert.assertNotNull(simple);

        Entry[] attrs = new Entry[]{ServiceLogEvent.getEventDescriptor()};
        ServiceTemplate template = new ServiceTemplate(null, null, attrs);
        ServiceItem[] items = testManager.getServiceDiscoveryManager().lookup(template,
View Full Code Here

            Assert.assertEquals(1, opstring.getServices().length);
            testManager.waitForDeployment(mgr);
            ServiceBeanInstance[] instances =
                cybernode.getServiceBeanInstances(opstring.getServices()[0]);
            Assert.assertEquals(1, instances.length);
            Simple simple = (Simple)instances[0].getService();
            Assert.assertEquals("Hello visitor : 1", simple.hello("hi"));

            Assert.assertEquals(configFilesInTmp, countTempConfigFiles());

            testManager.undeploy(opstring.getName());
        } catch(Exception e) {
View Full Code Here

            sMon.waitFor(2);
            instances =
                cybernode.getServiceBeanInstances(opstring.getServices()[0]);
            Assert.assertEquals(2, instances.length);
            for(ServiceBeanInstance sbi : instances) {
                Simple h = (Simple)sbi.getService();
                Assert.assertEquals("Hello visitor : 1", h.hello("hi"));
            }
            testManager.undeploy(opstring.getName());
        } catch(Exception e) {
            thrown = e;
            e.printStackTrace();
View Full Code Here

            Assert.assertEquals(1, opstring.getServices().length);
            testManager.waitForDeployment(mgr);
            ServiceBeanInstance[] instances =
                cybernode.getServiceBeanInstances(opstring.getServices()[0]);
            Assert.assertEquals(1, instances.length);
            Simple simple = (Simple)instances[0].getService();
            Assert.assertEquals("Hello visitor : 1", simple.hello("hi"));
            mgr.decrement(instances[0], true, true);
            ServiceMonitor<Simple> sMon =
                new ServiceMonitor<Simple>(testManager.getServiceDiscoveryManager(), Simple.class);
            sMon.waitFor(0);
            instances =
View Full Code Here

TOP

Related Classes of org.rioproject.test.simple.Simple

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.