[jbosscache-commits] JBoss Cache SVN: r4534 - in core/trunk/src/test/java/org/jboss/cache: optimistic and 1 other directory.
jbosscache-commits at lists.jboss.org
jbosscache-commits at lists.jboss.org
Wed Oct 3 17:54:36 EDT 2007
Author: manik.surtani at jboss.com
Date: 2007-10-03 17:54:36 -0400 (Wed, 03 Oct 2007)
New Revision: 4534
Modified:
core/trunk/src/test/java/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java
core/trunk/src/test/java/org/jboss/cache/optimistic/ConcurrentTransactionTest.java
Log:
IDE Formatting
Modified: core/trunk/src/test/java/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java
===================================================================
--- core/trunk/src/test/java/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java 2007-10-03 21:43:26 UTC (rev 4533)
+++ core/trunk/src/test/java/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java 2007-10-03 21:54:36 UTC (rev 4534)
@@ -6,16 +6,6 @@
*/
package org.jboss.cache.buddyreplication;
-import static org.testng.AssertJUnit.assertEquals;
-import static org.testng.AssertJUnit.assertFalse;
-import static org.testng.AssertJUnit.assertNull;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-
import org.jboss.cache.Cache;
import org.jboss.cache.CacheImpl;
import org.jboss.cache.CacheSPI;
@@ -29,17 +19,25 @@
import org.jboss.cache.factories.XmlConfigurationParser;
import org.jboss.cache.misc.TestingUtil;
import org.jboss.cache.util.CachePrinter;
+import static org.testng.AssertJUnit.*;
import org.testng.annotations.AfterMethod;
import org.testng.annotations.BeforeMethod;
+import org.testng.annotations.Test;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import java.util.HashMap;
+import java.util.Map;
+
/**
* Tests handling of the buddy backup region during region
* activation and inactivation
*
* @author Brian Stansberry
*/
+ at Test
public class BuddyBackupActivationInactivationTest extends BuddyReplicationTestsBase
{
public static final Fqn<String> A = Fqn.fromString("/a");
@@ -130,9 +128,9 @@
}
protected CacheImpl<Object, Object> createCache(String cacheID,
- boolean sync,
- boolean useMarshalling,
- boolean startCache)
+ boolean sync,
+ boolean useMarshalling,
+ boolean startCache)
throws Exception
{
if (caches.get(cacheID) != null)
Modified: core/trunk/src/test/java/org/jboss/cache/optimistic/ConcurrentTransactionTest.java
===================================================================
--- core/trunk/src/test/java/org/jboss/cache/optimistic/ConcurrentTransactionTest.java 2007-10-03 21:43:26 UTC (rev 4533)
+++ core/trunk/src/test/java/org/jboss/cache/optimistic/ConcurrentTransactionTest.java 2007-10-03 21:54:36 UTC (rev 4534)
@@ -5,19 +5,7 @@
* See terms of license at gnu.org.
*/
package org.jboss.cache.optimistic;
-import static org.testng.AssertJUnit.assertEquals;
-import static org.testng.AssertJUnit.assertNotNull;
-import static org.testng.AssertJUnit.assertNull;
-import static org.testng.AssertJUnit.assertTrue;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.concurrent.CopyOnWriteArrayList;
-import java.util.concurrent.CountDownLatch;
-
-import javax.transaction.Transaction;
-import javax.transaction.TransactionManager;
-
import org.jboss.cache.CacheSPI;
import org.jboss.cache.Fqn;
import org.jboss.cache.InvocationContext;
@@ -27,12 +15,22 @@
import org.jboss.cache.interceptors.TxInterceptor;
import org.jboss.cache.marshall.MethodDeclarations;
import org.jboss.cache.misc.TestingUtil;
+import static org.testng.AssertJUnit.*;
import org.testng.annotations.AfterMethod;
import org.testng.annotations.BeforeMethod;
+import org.testng.annotations.Test;
+import javax.transaction.Transaction;
+import javax.transaction.TransactionManager;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.concurrent.CopyOnWriteArrayList;
+import java.util.concurrent.CountDownLatch;
+
/**
* @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
*/
+ at Test
public class ConcurrentTransactionTest extends AbstractOptimisticTestCase
{
private CacheSPI<Object, Object> cache;
@@ -257,7 +255,8 @@
{
final String slowThreadName = "SLOW";
final String fastThreadName = "FAST";
- Interceptor slowdownInterceptor = new Interceptor() {
+ Interceptor slowdownInterceptor = new Interceptor()
+ {
public Object invoke(InvocationContext ctx) throws Throwable
{
if (Thread.currentThread().getName().equals(slowThreadName))
@@ -291,7 +290,8 @@
{
final String slowThreadName = "SLOW";
final String fastThreadName = "FAST";
- Interceptor slowdownInterceptor = new Interceptor() {
+ Interceptor slowdownInterceptor = new Interceptor()
+ {
public Object invoke(InvocationContext ctx) throws Throwable
{
if (Thread.currentThread().getName().equals(slowThreadName) && ctx.getMethodCall().getMethodId() == MethodDeclarations.optimisticPrepareMethod_id)
More information about the jbosscache-commits
mailing list