View Javadoc

1   /*
2    * $Id: DefaultThreadingProfileTestCase.java 19191 2010-08-25 21:05:23Z tcarlson $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  
11  package org.mule.config;
12  
13  import org.mule.api.config.ThreadingProfile;
14  import org.mule.tck.AbstractMuleTestCase;
15  
16  public class DefaultThreadingProfileTestCase extends AbstractMuleTestCase
17  {
18  
19      public void testDefaultThreadingProfile()
20      {
21          assertNotNull(muleContext.getDefaultThreadingProfile());
22          assertEquals(ThreadingProfile.DEFAULT_MAX_THREADS_ACTIVE, muleContext.getDefaultThreadingProfile()
23              .getMaxThreadsActive());
24          assertEquals(ThreadingProfile.DEFAULT_MAX_THREADS_IDLE, muleContext.getDefaultThreadingProfile()
25              .getMaxThreadsIdle());
26          assertEquals(ThreadingProfile.DEFAULT_MAX_THREAD_TTL, muleContext.getDefaultThreadingProfile()
27              .getThreadTTL());
28          assertEquals(ThreadingProfile.DEFAULT_MAX_BUFFER_SIZE, muleContext.getDefaultThreadingProfile()
29              .getMaxBufferSize());
30          assertEquals(ThreadingProfile.DEFAULT_POOL_EXHAUST_ACTION, muleContext.getDefaultThreadingProfile()
31              .getPoolExhaustedAction());
32          assertEquals(ThreadingProfile.DEFAULT_THREAD_WAIT_TIMEOUT, muleContext.getDefaultThreadingProfile()
33              .getThreadWaitTimeout());
34          assertEquals(ThreadingProfile.DEFAULT_DO_THREADING, muleContext.getDefaultThreadingProfile()
35              .isDoThreading());
36      }
37  
38  }