Examples of SetupTaskAware


Examples of org.apache.qpid.junit.extensions.SetupTaskAware

        {
            // Check that the test to have an in-vm broker setup/teardown task added to it, is actually a framework
            // test that can handle setup tasks.
            if ((test instanceof SetupTaskAware))
            {
                SetupTaskAware frameworkTest = (SetupTaskAware) test;

                frameworkTest.chainSetupTask(new Runnable()
                    {
                        public void run()
                        {
                            // Ensure that the in-vm broker is created.
                            try
                            {
                                TransportConnection.createVMBroker(1);
                            }
                            catch (AMQVMBrokerCreationException e)
                            {
                                throw new RuntimeException("In-VM broker creation failed: " + e.getMessage(), e);
                            }
                        }
                    });

                frameworkTest.chainTearDownTask(new Runnable()
                    {
                        public void run()
                        {
                            // Ensure that the in-vm broker is cleaned up so that the next test starts afresh.
                            TransportConnection.killVMBroker(1);
View Full Code Here

Examples of org.apache.qpid.junit.extensions.SetupTaskAware

        {
            // Check that the test to have an in-vm broker setup/teardown task added to it, is actually a framework
            // test that can handle setup tasks.
            if ((test instanceof SetupTaskAware))
            {
                SetupTaskAware frameworkTest = (SetupTaskAware) test;

                frameworkTest.chainSetupTask(new Runnable()
                    {
                        public void run()
                        {
                            // Ensure that the in-vm broker is created.
                            try
                            {
                                ApplicationRegistry.getInstance(1);
                                TransportConnection.createVMBroker(1);
                            }
                            catch (AMQVMBrokerCreationException e)
                            {
                                throw new RuntimeException("In-VM broker creation failed: " + e.getMessage(), e);
                            }
                        }
                    });

                frameworkTest.chainTearDownTask(new Runnable()
                    {
                        public void run()
                        {
                            // Ensure that the in-vm broker is cleaned up so that the next test starts afresh.
                            TransportConnection.killVMBroker(1);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.