class InternalTestPlan extends TestPlan
TestPlan.Visitor| Modifier and Type | Field and Description |
|---|---|
private TestPlan |
delegate |
private LauncherDiscoveryResult |
discoveryResult |
private java.util.concurrent.atomic.AtomicBoolean |
executionStarted |
| Modifier | Constructor and Description |
|---|---|
private |
InternalTestPlan(LauncherDiscoveryResult discoveryResult,
TestPlan delegate) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(TestIdentifier testIdentifier)
Add the supplied
TestIdentifier to this test plan. |
void |
addInternal(TestIdentifier testIdentifier) |
boolean |
containsTests()
Return whether this test plan contains any tests.
|
long |
countTestIdentifiers(java.util.function.Predicate<? super TestIdentifier> predicate)
Count all
TestIdentifiers that satisfy the
given predicate. |
(package private) static InternalTestPlan |
from(LauncherDiscoveryResult discoveryResult) |
java.util.Set<TestIdentifier> |
getChildren(java.lang.String parentId)
Get the children of the supplied unique ID.
|
java.util.Set<TestIdentifier> |
getChildren(TestIdentifier parent)
Get the children of the supplied
TestIdentifier. |
java.util.Set<TestIdentifier> |
getChildren(UniqueId parentId)
Get the children of the supplied unique ID.
|
TestPlan |
getDelegate() |
java.util.Set<TestIdentifier> |
getDescendants(TestIdentifier parent)
Get all descendants of the supplied
TestIdentifier (i.e.,
all of its children and their children, recursively). |
(package private) LauncherDiscoveryResult |
getDiscoveryResult() |
java.util.Optional<TestIdentifier> |
getParent(TestIdentifier child)
Get the parent of the supplied
TestIdentifier. |
java.util.Set<TestIdentifier> |
getRoots()
Get the root
TestIdentifiers for this test plan. |
TestIdentifier |
getTestIdentifier(java.lang.String uniqueId)
Get the
TestIdentifier with the supplied unique ID. |
TestIdentifier |
getTestIdentifier(UniqueId uniqueId)
Get the
TestIdentifier with the supplied unique ID. |
(package private) void |
markStarted() |
accept, from, getConfigurationParametersprivate final java.util.concurrent.atomic.AtomicBoolean executionStarted
private final LauncherDiscoveryResult discoveryResult
private final TestPlan delegate
private InternalTestPlan(LauncherDiscoveryResult discoveryResult, TestPlan delegate)
static InternalTestPlan from(LauncherDiscoveryResult discoveryResult)
void markStarted()
LauncherDiscoveryResult getDiscoveryResult()
public TestPlan getDelegate()
public void add(TestIdentifier testIdentifier)
TestPlanTestIdentifier to this test plan.public void addInternal(TestIdentifier testIdentifier)
addInternal in class TestPlanpublic java.util.Set<TestIdentifier> getRoots()
TestPlanTestIdentifiers for this test plan.public java.util.Optional<TestIdentifier> getParent(TestIdentifier child)
TestPlanTestIdentifier.public java.util.Set<TestIdentifier> getChildren(TestIdentifier parent)
TestPlanTestIdentifier.getChildren in class TestPlanparent - the identifier to look up the children for; never nullTestPlan.getChildren(UniqueId)public java.util.Set<TestIdentifier> getChildren(java.lang.String parentId)
TestPlangetChildren in class TestPlanparentId - the unique ID to look up the children for; never
null or blankTestPlan.getChildren(TestIdentifier)public java.util.Set<TestIdentifier> getChildren(UniqueId parentId)
TestPlangetChildren in class TestPlanparentId - the unique ID to look up the children for; never
nullTestPlan.getChildren(TestIdentifier)public TestIdentifier getTestIdentifier(java.lang.String uniqueId) throws PreconditionViolationException
TestPlanTestIdentifier with the supplied unique ID.getTestIdentifier in class TestPlanuniqueId - the unique ID to look up the identifier for; never
null or blanknullPreconditionViolationException - if no TestIdentifier
with the supplied unique ID is present in this test planpublic TestIdentifier getTestIdentifier(UniqueId uniqueId)
TestPlanTestIdentifier with the supplied unique ID.getTestIdentifier in class TestPlanuniqueId - the unique ID to look up the identifier for; never
nullnullpublic long countTestIdentifiers(java.util.function.Predicate<? super TestIdentifier> predicate)
TestPlanTestIdentifiers that satisfy the
given predicate.countTestIdentifiers in class TestPlanpredicate - a predicate which returns true for identifiers
to be counted; never nullpublic java.util.Set<TestIdentifier> getDescendants(TestIdentifier parent)
TestPlanTestIdentifier (i.e.,
all of its children and their children, recursively).getDescendants in class TestPlanparent - the identifier to look up the descendants for; never nullpublic boolean containsTests()
TestPlanA test plan contains tests, if at least one of the contained engine descriptors contains tests.
containsTests in class TestPlantrue if this test plan contains testsTestDescriptor.containsTests(TestDescriptor)