public class OptimisticSessionRefreshTest extends PessimisticSessionRefreshTest { private static final String CACHE_CONFIG = "optimistic-entity"; /** * Create a new OptimisticSessionRefreshTest. * * @param x */ public OptimisticSessionRefreshTest(String x) { super(x); } public static Test suite() throws Exception { TestSuite suite = new TestSuite(OptimisticSessionRefreshTest.class); String[] acctClasses = { OUR_PACKAGE + ".Account", OUR_PACKAGE + ".AccountHolder" }; return new IsolatedCacheTestSetup(suite, acctClasses, CACHE_CONFIG); } @Override protected String getEntityCacheConfigName() { return CACHE_CONFIG
public class PessimisticRepeatableSessionRefreshTest extends PessimisticSessionRefreshTest { private static final String CACHE_CONFIG = "pessimistic-entity-repeatable"; /** * Create a new PessimisticRepeatableSessionRefreshTest. * * @param x */ public PessimisticRepeatableSessionRefreshTest(String x) { super(x); } public static Test suite() throws Exception { TestSuite suite = new TestSuite(PessimisticRepeatableSessionRefreshTest.class); String[] acctClasses = { OUR_PACKAGE + ".Account", OUR_PACKAGE + ".AccountHolder" }; return new IsolatedCacheTestSetup(suite, acctClasses, CACHE_CONFIG); } @Override protected String getEntityCacheConfigName() { return CACHE_CONFIG
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/cache-jbosscache2/src/test/java/org/hibernate/test/cache/jbc2/functional/OptimisticSessionRefreshTest.java File path: /hibernate-distribution-3.3.2.GA/project/cache-jbosscache2/src/test/java/org/hibernate/test/cache/jbc2/functional/PessimisticRepeatableSessionRefreshTest.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
public class OptimisticSessionRefreshTest extends PessimisticSessionRefreshTest
1
public class PessimisticRepeatableSessionRefreshTest extends PessimisticSessionRefreshTest
2
{
2
{
3
   
3
   
4
   private static final String CACHE_CONFIG = "optimistic-entity";
4
   private static final String CACHE_CONFIG = "pessimistic-entity-repeatable";
5
   /**
5
   /**
6
    * Create a new OptimisticSessionRefreshTest.
6
    * Create a new PessimisticRepeatableSessionRefreshTest.
7
    * 
7
    * 
8
    * @param x
8
    * @param x
9
    */
9
    */
10
   public OptimisticSessionRefreshTest(String x)
10
   public PessimisticRepeatableSessionRefreshTest(String x)
11
   {
11
   {
12
      super(x);
12
      super(x);
13
   }
13
   }
14
   
14
   
15
   public static Test suite() throws Exception {
15
   public static Test suite() throws Exception {
16
       TestSuite suite = new TestSuite(OptimisticSessionRefreshTest.class);
16
       TestSuite suite = new TestSuite(PessimisticRepeatableSessionRefreshTest.class);
17
       String[] acctClasses = { OUR_PACKAGE + ".Account", OUR_PACKAGE + ".AccountHolder" };
17
       String[] acctClasses = { OUR_PACKAGE + ".Account", OUR_PACKAGE + ".AccountHolder" };
18
       return new IsolatedCacheTestSetup(suite, acctClasses, CACHE_CONFIG);
18
       return new IsolatedCacheTestSetup(suite, acctClasses, CACHE_CONFIG);
19
   }
19
   }
20
   @Override
20
   @Override
21
   protected String getEntityCacheConfigName() {
21
   protected String getEntityCacheConfigName() {
22
       return CACHE_CONFIG
22
       return CACHE_CONFIG
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0