Interface TestsDao
- All Superinterfaces:
BambooObjectDao<TestClass>
- All Known Implementing Classes:
TestsHibernateDao
Dao for retrieving and manipulating Test Objects (e.g TestClass, TestCase)
-
Method Summary
Modifier and TypeMethodDescriptionlong
Count all TestClass records@NotNull Collection<? extends TestClass>
findAll()
@Nullable TestClass
findById
(long testClassId) Find a specific testClass by idgetTestClassesMapForPlan
(Plan plan, long masterJobId, int cutoffBuildNumber) Retrieve all test classes attached to a specific plan in a build later or equal to cutoffBuildNumber.long
scrollTestClassesForExport
(@NotNull Consumer<TestClass> consumer) Scroll through and execute function for each of TestClass records Objects passed to function are not fully initialized.@NotNull org.hibernate.ScrollableResults
Scroll through all test classes attached to a specific plan, alphabetically by test class name.Methods inherited from interface com.atlassian.bamboo.persistence3.BambooObjectDao
countAll, countWithRestriction, delete, deleteAll, findAll, findById, merge, save, saveAll
-
Method Details
-
findById
Find a specific testClass by id- Parameters:
testClassId
- of the test class you want to find- Returns:
- the testClass corresponding to the id provided.
-
findAll
-
getTestClassesMapForPlan
@NotNull @NotNull Multimap<TestClass,TestCase> getTestClassesMapForPlan(Plan plan, long masterJobId, int cutoffBuildNumber) Retrieve all test classes attached to a specific plan in a build later or equal to cutoffBuildNumber.- Returns:
- a multimap representing relationship between TestClasses and TestCases.
-
scrollThroughTestClassesForPlan
Scroll through all test classes attached to a specific plan, alphabetically by test class name. Only forward scroll should be used.- Parameters:
plan
- the tests are attached to- Returns:
- a list of TestClass attached to a plan.
-
countTestClasses
long countTestClasses()Count all TestClass records- Returns:
- number of TestClass records
-
scrollTestClassesForExport
Scroll through and execute function for each of TestClass records Objects passed to function are not fully initialized. Collections are empty and related objects have only id set.- Parameters:
consumer
- consumer to accept each of the TestClass records- Returns:
- number of traversed rows
-