Skip to content

Commit

Permalink
More refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
SarahFrench committed Mar 28, 2024
1 parent b939f8f commit 20858ab
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions mmv1/third_party/terraform/.teamcity/tests/sweepers.kt
Original file line number Diff line number Diff line change
Expand Up @@ -94,21 +94,18 @@ class SweeperTests {

@Test
fun projectSweepersRunAfterServiceSweepers() {
val project = googleCloudRootProject(testContextParameters())
val root = googleCloudRootProject(testContextParameters())

// Find GA nightly test project's service sweeper
val gaNightlyTests: Project = getSubProject(project, gaProjectName, nightlyTestsProjectName)
val gaNightlyTests: Project = getNestedProjectFromRoot(root, gaProjectName, nightlyTestsProjectName)
val sweeperGa: BuildType = getBuildFromProject(gaNightlyTests, ServiceSweeperName)

// Find Beta nightly test project's service sweeper
val betaNightlyTests : Project = getSubProject(project, betaProjectName, nightlyTestsProjectName)
val betaNightlyTests : Project = getNestedProjectFromRoot(root, betaProjectName, nightlyTestsProjectName)
val sweeperBeta: BuildType = getBuildFromProject(betaNightlyTests, ServiceSweeperName)

// Find Project sweeper project's build
val projectSweeperProject : Project? = project.subProjects.find { p-> p.name == projectSweeperProjectName}
if (projectSweeperProject == null) {
Assert.fail("Could not find the Project Sweeper project")
}
val projectSweeperProject = getSubProject(root, projectSweeperProjectName)
val projectSweeper: BuildType = getBuildFromProject(projectSweeperProject!!, ProjectSweeperName)

// Check only one schedule trigger is on the builds in question
Expand Down

0 comments on commit 20858ab

Please sign in to comment.