Class TestQuarantineManagerImpl
java.lang.Object
com.atlassian.bamboo.resultsummary.tests.TestQuarantineManagerImpl
- All Implemented Interfaces:
TestQuarantineManager
-
Field Summary
Fields inherited from interface com.atlassian.bamboo.resultsummary.tests.TestQuarantineManager
QUARANTINE_TEST_KEY
-
Constructor Summary
ConstructorDescriptionTestQuarantineManagerImpl
(TestCaseDao testCaseDao, TestCaseResultDao testCaseResultDao, TestsManager testsManager, CachedPlanManager cachedPlanManager, com.atlassian.event.api.EventPublisher eventPublisher) -
Method Summary
Modifier and TypeMethodDescriptionint
Returns the number of tests current qurantined for this plangetCurrentlyQuarantinedTests
(@NotNull ImmutableChain chain) Get a list ofTestCase
of all the tests currently quarantined for a given plangetCurrentlyQuarantinedTests
(@NotNull ImmutableJob job) Get a list of TestClass and TestCase names of all the tests currently quarantined for a given job In string form for use in the BuildContext custom config@NotNull List<TestCaseResult>
getQuarantinedTestsListForBuildResult
(@NotNull BuildResultsSummary buildResultsSummary) ReturnsList
ofTestCaseResult
that are quarantined for a given build result.@Nullable List<TestCaseResult>
getQuarantinedTestsListForChainResult
(@NotNull ChainResultsSummary chainResultsSummary) Get a list ofTestCase
of all the tests quarantined for a given chain resultvoid
quarantineTest
(long testId, @NotNull com.atlassian.user.User user, @NotNull Date date) Quarantines a given testvoid
quarantineTest
(long testId, @NotNull com.atlassian.user.User user, @NotNull Date date, @Nullable Date expiryDate) Quarantines a given test until a specified datevoid
unleashTest
(long testId, com.atlassian.user.User user) Unleash a given testMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.bamboo.resultsummary.tests.TestQuarantineManager
unleashTest
-
Constructor Details
-
TestQuarantineManagerImpl
public TestQuarantineManagerImpl(TestCaseDao testCaseDao, TestCaseResultDao testCaseResultDao, TestsManager testsManager, CachedPlanManager cachedPlanManager, com.atlassian.event.api.EventPublisher eventPublisher)
-
-
Method Details
-
quarantineTest
public void quarantineTest(long testId, @NotNull @NotNull com.atlassian.user.User user, @NotNull @NotNull Date date) Description copied from interface:TestQuarantineManager
Quarantines a given test- Specified by:
quarantineTest
in interfaceTestQuarantineManager
- Parameters:
testId
- - Id of the required test caseuser
- - User quarantining testdate
- - date of test quarantine
-
quarantineTest
public void quarantineTest(long testId, @NotNull @NotNull com.atlassian.user.User user, @NotNull @NotNull Date date, @Nullable @Nullable Date expiryDate) Description copied from interface:TestQuarantineManager
Quarantines a given test until a specified date- Specified by:
quarantineTest
in interfaceTestQuarantineManager
- Parameters:
testId
- - Id of the required test caseuser
- - User quarantining testdate
- - date of test quarantineexpiryDate
- - date of expiry for the quarantine, can be null for permanent quarantine
-
unleashTest
public void unleashTest(long testId, com.atlassian.user.User user) Description copied from interface:TestQuarantineManager
Unleash a given test- Specified by:
unleashTest
in interfaceTestQuarantineManager
- Parameters:
testId
- - ID of required test caseuser
- - user who unleashed test
-
getCurrentlyQuarantinedTests
@NotNull public @NotNull List<TestCase> getCurrentlyQuarantinedTests(@NotNull @NotNull ImmutableChain chain) Description copied from interface:TestQuarantineManager
Get a list ofTestCase
of all the tests currently quarantined for a given plan- Specified by:
getCurrentlyQuarantinedTests
in interfaceTestQuarantineManager
- Parameters:
chain
- - the chain representing a plan to get quarantined tests for- Returns:
- A list of
TestCase
-
countCurrentlyQuarantinedTests
Description copied from interface:TestQuarantineManager
Returns the number of tests current qurantined for this plan- Specified by:
countCurrentlyQuarantinedTests
in interfaceTestQuarantineManager
- Returns:
-
getQuarantinedTestsListForChainResult
@Nullable public @Nullable List<TestCaseResult> getQuarantinedTestsListForChainResult(@NotNull @NotNull ChainResultsSummary chainResultsSummary) Description copied from interface:TestQuarantineManager
Get a list ofTestCase
of all the tests quarantined for a given chain result- Specified by:
getQuarantinedTestsListForChainResult
in interfaceTestQuarantineManager
- Parameters:
chainResultsSummary
- - results summary of the build you need quarantined tests for- Returns:
- a list of
TestCase
of all the tests quarantined for a chain result
-
getQuarantinedTestsListForBuildResult
@NotNull public @NotNull List<TestCaseResult> getQuarantinedTestsListForBuildResult(@NotNull @NotNull BuildResultsSummary buildResultsSummary) Description copied from interface:TestQuarantineManager
ReturnsList
ofTestCaseResult
that are quarantined for a given build result.- Specified by:
getQuarantinedTestsListForBuildResult
in interfaceTestQuarantineManager
- Parameters:
buildResultsSummary
- - results summary of the build you need quarantined tests for- Returns:
List
ofTestCaseResult
. Empty list if no quarantined tests
-
getCurrentlyQuarantinedTests
@NotNull public @NotNull List<TestCase> getCurrentlyQuarantinedTests(@NotNull @NotNull ImmutableJob job) Description copied from interface:TestQuarantineManager
Get a list of TestClass and TestCase names of all the tests currently quarantined for a given job In string form for use in the BuildContext custom config- Specified by:
getCurrentlyQuarantinedTests
in interfaceTestQuarantineManager
- Parameters:
job
- to get quarantined tests for- Returns:
- A list of
TestCase
-