Package org.mule.tck.probe

Examples of org.mule.tck.probe.PollingProber


        });
    }

    public void assertUndeploymentSuccess(final DeploymentListener listener, final String appName)
    {
        Prober prober = new PollingProber(DEPLOYMENT_TIMEOUT, 100);
        prober.check(new Probe()
        {
            public boolean isSatisfied()
            {
                try
                {
View Full Code Here


            assertTrue(fileReceiveLatch.await(30, TimeUnit.SECONDS));

            // the output file should exist now
            // check that the files with the correct output pattern were generated
            Prober prober = new PollingProber(2000, 50);

            prober.check(new Probe()
            {
                @Override
                public boolean isSatisfied()
                {
                  return FileUtils.newFile(myDir, myFileName1).exists() && FileUtils.newFile(myDir2, myFileName2).exists();
View Full Code Here

    public void testAsynch() throws Exception
    {
        sendMessage("vm://testAsynch");

        file = new File(FILE_PATH);
        Prober prober = new PollingProber(10000, 2000);
        prober.check(new FileCompleteProbe());
    }
View Full Code Here

    public synchronized void disposeMuleContext(final MuleContext muleContext)
    {
        disposedContexts.add(muleContext);
        muleContext.dispose();
        new PollingProber(10000, 100).check(new Probe()
        {
            @Override
            public boolean isSatisfied()
            {
                return muleContext.isDisposed();
View Full Code Here

        // Need to explicitly dispose manager here to get disposal notifications
        muleContext.dispose();
        // allow shutdown to complete (or get concurrent mod errors and/or miss
        // notifications)

        PollingProber prober = new PollingProber(30000, 2000);
        prober.check(new JUnitProbe()
        {

            @Override
            protected boolean test() throws Exception
            {
View Full Code Here

    {
        LocalMuleClient client = muleContext.getClient();
        client.dispatch("vm://testInput", TEST_MESSAGE, null);
        client.dispatch("vm://testInput", TEST_MESSAGE, null);

        Prober prober = new PollingProber(1000, 10);
        prober.check(new Probe()
        {
            @Override
            public boolean isSatisfied()
            {
                return count == 2;
View Full Code Here

        MuleClient client = muleContext.getClient();
        client.dispatch("vm://in5", "test", null);

        assertExceptionMessage(client.request("vm://out5", RECEIVE_TIMEOUT));

        Prober prober = new PollingProber(5000, 100);
        prober.check(new Probe()
        {
            @Override
            public boolean isSatisfied()
            {
                return !service.getLifecycleState().isStarted();
View Full Code Here

public class DeploymentTestUtils
{

    public static void assertFileExists(File pluginsDir, String filePath)
    {
        Prober prober = new PollingProber(5000, 100);
        File marker = new File(pluginsDir, filePath);
        prober.check(new FileExists(marker));
    }
View Full Code Here

        assertThat(exceptionStrategyStartNotification.getResourceIdentifier(), is(exceptionStrategyEndNotification.getResourceIdentifier()));
    }

    private void assertNotificationsArrived()
    {
        PollingProber prober = new PollingProber(TIMEOUT_MILLIS, POLL_DELAY_MILLIS);
        prober.check(new JUnitProbe()
        {
            @Override
            protected boolean test() throws Exception
            {
                assertThat(exceptionStrategyStartNotification, is(not(nullValue())));
View Full Code Here

    private void executeScenario(final String inQueue,final String outQueue) throws Exception
    {
        getMuleContextForApp(CLIENT_APP).getClient().dispatch(queueAddress(inQueue), "test", null);
        final AtomicReference<MuleMessage> response = new AtomicReference<MuleMessage>();
        new PollingProber(10000,100).check(new Probe()
        {
            @Override
            public boolean isSatisfied()
            {
                MuleMessage responseMessage;
View Full Code Here

TOP

Related Classes of org.mule.tck.probe.PollingProber

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.