-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add 7.0 major version testing project
- Loading branch information
1 parent
c8de2fa
commit 3beebf6
Showing
4 changed files
with
111 additions
and
2 deletions.
There are no files selected for viewing
105 changes: 105 additions & 0 deletions
105
...form/.teamcity/components/projects/feature_branches/FEATURE-BRANCH-major-release-7.0.0.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
/* | ||
* Copyright (c) HashiCorp, Inc. | ||
* SPDX-License-Identifier: MPL-2.0 | ||
*/ | ||
|
||
// This file is controlled by MMv1, any changes made here will be overwritten | ||
|
||
package projects.feature_branches | ||
|
||
import ProviderNameBeta | ||
import ProviderNameGa | ||
import builds.* | ||
import jetbrains.buildServer.configs.kotlin.Project | ||
import jetbrains.buildServer.configs.kotlin.vcs.GitVcsRoot | ||
import projects.reused.nightlyTests | ||
import replaceCharsId | ||
|
||
const val branchName = "FEATURE-BRANCH-major-release-7.0.0" | ||
|
||
// VCS Roots specifically for pulling code from the feature branches in the downstream repos | ||
|
||
object HashicorpVCSRootGa_featureBranchMajorRelease700: GitVcsRoot({ | ||
name = "VCS root for the hashicorp/terraform-provider-${ProviderNameGa} repo @ refs/heads/${branchName}" | ||
url = "https://github.com/hashicorp/terraform-provider-${ProviderNameGa}" | ||
branch = "refs/heads/${branchName}" | ||
branchSpec = """ | ||
+:(refs/heads/*) | ||
-:refs/pulls/* | ||
""".trimIndent() | ||
}) | ||
|
||
object HashicorpVCSRootBeta_featureBranchMajorRelease700: GitVcsRoot({ | ||
name = "VCS root for the hashicorp/terraform-provider-${ProviderNameBeta} repo @ refs/heads/${branchName}" | ||
url = "https://github.com/hashicorp/terraform-provider-${ProviderNameBeta}" | ||
branch = "refs/heads/${branchName}" | ||
branchSpec = """ | ||
+:(refs/heads/*) | ||
-:refs/pulls/* | ||
""".trimIndent() | ||
}) | ||
|
||
fun featureBranchMajorRelease700_Project(allConfig: AllContextParameters): Project { | ||
|
||
val projectId = replaceCharsId(branchName) | ||
val gaProjectId = replaceCharsId(projectId + "_GA") | ||
val betaProjectId= replaceCharsId(projectId + "_BETA") | ||
|
||
// Get config for using the GA and Beta identities | ||
val gaConfig = getGaAcceptanceTestConfig(allConfig) | ||
val betaConfig = getBetaAcceptanceTestConfig(allConfig) | ||
|
||
return Project{ | ||
id(projectId) | ||
name = "7.0.0 Major Release Testing" | ||
description = "Subproject for testing feature branch $branchName" | ||
|
||
// Register feature branch-specific VCS roots in the project | ||
vcsRoot(HashicorpVCSRootGa_featureBranchMajorRelease700) | ||
vcsRoot(HashicorpVCSRootBeta_featureBranchMajorRelease700) | ||
|
||
// Nested Nightly Test project that uses hashicorp/terraform-provider-google | ||
subProject( | ||
Project{ | ||
id(gaProjectId) | ||
name = "Google" | ||
subProject( | ||
nightlyTests( | ||
gaProjectId, | ||
ProviderNameGa, | ||
HashicorpVCSRootGa_featureBranchMajorRelease700, | ||
gaConfig, | ||
NightlyTriggerConfiguration( | ||
branch = "refs/heads/${branchName}", // Make triggered builds use the feature branch | ||
daysOfWeek = "5" // Thursday for GA, TeamCity numbers days Sun=1...Sat=7 | ||
), | ||
) | ||
) | ||
} | ||
) | ||
|
||
// Nested Nightly Test project that uses hashicorp/terraform-provider-google-beta | ||
subProject( | ||
Project { | ||
id(betaProjectId) | ||
name = "Google Beta" | ||
subProject( | ||
nightlyTests( | ||
betaProjectId, | ||
ProviderNameBeta, | ||
HashicorpVCSRootBeta_featureBranchMajorRelease700, | ||
betaConfig, | ||
NightlyTriggerConfiguration( | ||
branch = "refs/heads/${branchName}", // Make triggered builds use the feature branch | ||
daysOfWeek="6" // Friday for Beta, TeamCity numbers days Sun=1...Sat=7 | ||
), | ||
) | ||
) | ||
} | ||
) | ||
|
||
params { | ||
readOnlySettings() | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters