## org.exist.xmldb.test.concurrent
Class ConcurrentTestBase

    java.lang.Object
      junit.framework.Assert
          junit.framework.TestCase
              org.exist.xmldb.test.concurrent.ConcurrentTestBase

All Implemented Interfaces:
  junit.framework.Test

Direct Known Subclasses:
  ComplexUpdateTest, ConcurrentAttrUpdateTest, ConcurrentQueryTest, ConcurrentQueryUpdateTest, ConcurrentResourceTest, ConcurrentResourceTest2, ConcurrentResourceTest3, ConcurrentXUpdateTest, FragmentsTest, TextUpdateTest, ValueIndexUpdateTest

public abstract class ConcurrentTestBase
extends junit.framework.TestCase

Abstract base class for concurrent tests.

Author:
  wolf

Constructor Summary
`ConcurrentTestBase(java.lang.String name, java.lang.String uri, java.lang.String testCollection)`

Method Summary
`void` `addAction(Action action, int repeat, long delayBeforeStart, long delay)` Add an `Action` to the list of actions that will be processed concurrently.
`Collection` `getTestCollection()`
`void` `testConcurrent()`

Methods inherited from class junit.framework.TestCase
`countTestCases, getName, run, run, runBare, setName, toString`

Methods inherited from class junit.framework.Assert

`assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### ConcurrentTestBase

    public ConcurrentTestBase(java.lang.String name,
                              java.lang.String uri,
                              java.lang.String testCollection)

Parameters:
  `name` - the name of the test.
  `uri` - the XMLDB URI of the root collection.
  `testCollection` - the name of the collection that will be created for the test.

Method Detail

### addAction

    public void addAction(Action action,
                          int repeat,
                          long delayBeforeStart,
                          long delay)

  Add an `Action` to the list of actions that will be processed concurrently. Should be called after `#setUp()`.

  Parameters:
    `action` - the action.
    `repeat` - number of times the actions should be repeated.

### getTestCollection

    public Collection getTestCollection()

### testConcurrent

    public void testConcurrent()

Copyright (C) Wolfgang Meier. All rights reserved.