mirror of
https://github.com/apple/pkl.git
synced 2026-04-24 01:08:34 +02:00
Revert Gradle plugin tests to use deprecated API (#1011)
Using the replacement API fails with: "DefaultTaskContainer#register(String, Class, Action) on task set cannot be executed in the current context."
This commit is contained in:
@@ -23,7 +23,7 @@ tasks.addRule("Pattern: compatibilityTest[All|Releases|Latest|Candidate|Nightly|
|
|||||||
|
|
||||||
when (val taskNameSuffix = matchResult.groupValues[1]) {
|
when (val taskNameSuffix = matchResult.groupValues[1]) {
|
||||||
"All" ->
|
"All" ->
|
||||||
tasks.register("compatibilityTestAll") {
|
task("compatibilityTestAll") {
|
||||||
dependsOn(
|
dependsOn(
|
||||||
"compatibilityTestReleases",
|
"compatibilityTestReleases",
|
||||||
"compatibilityTestCandidate",
|
"compatibilityTestCandidate",
|
||||||
@@ -32,7 +32,7 @@ tasks.addRule("Pattern: compatibilityTest[All|Releases|Latest|Candidate|Nightly|
|
|||||||
}
|
}
|
||||||
// releases in configured range
|
// releases in configured range
|
||||||
"Releases" ->
|
"Releases" ->
|
||||||
tasks.register("compatibilityTestReleases") {
|
task("compatibilityTestReleases") {
|
||||||
val versionInfos = GradleVersionInfo.fetchReleases()
|
val versionInfos = GradleVersionInfo.fetchReleases()
|
||||||
val allVersions =
|
val allVersions =
|
||||||
versionInfos
|
versionInfos
|
||||||
@@ -49,7 +49,7 @@ tasks.addRule("Pattern: compatibilityTest[All|Releases|Latest|Candidate|Nightly|
|
|||||||
}
|
}
|
||||||
// latest release (if not developing against latest)
|
// latest release (if not developing against latest)
|
||||||
"Latest" ->
|
"Latest" ->
|
||||||
tasks.register("compatibilityTestLatest") {
|
task("compatibilityTestLatest") {
|
||||||
val versionInfo = GradleVersionInfo.fetchCurrent()
|
val versionInfo = GradleVersionInfo.fetchCurrent()
|
||||||
if (versionInfo.version == gradle.gradleVersion) {
|
if (versionInfo.version == gradle.gradleVersion) {
|
||||||
doLast {
|
doLast {
|
||||||
@@ -64,7 +64,7 @@ tasks.addRule("Pattern: compatibilityTest[All|Releases|Latest|Candidate|Nightly|
|
|||||||
}
|
}
|
||||||
// active release candidate (if any)
|
// active release candidate (if any)
|
||||||
"Candidate" ->
|
"Candidate" ->
|
||||||
tasks.register("compatibilityTestCandidate") {
|
task("compatibilityTestCandidate") {
|
||||||
val versionInfo = GradleVersionInfo.fetchRc()
|
val versionInfo = GradleVersionInfo.fetchRc()
|
||||||
if (versionInfo?.activeRc == true) {
|
if (versionInfo?.activeRc == true) {
|
||||||
dependsOn(createCompatibilityTestTask(versionInfo))
|
dependsOn(createCompatibilityTestTask(versionInfo))
|
||||||
@@ -74,7 +74,7 @@ tasks.addRule("Pattern: compatibilityTest[All|Releases|Latest|Candidate|Nightly|
|
|||||||
}
|
}
|
||||||
// latest nightly
|
// latest nightly
|
||||||
"Nightly" ->
|
"Nightly" ->
|
||||||
tasks.register("compatibilityTestNightly") {
|
task("compatibilityTestNightly") {
|
||||||
val versionInfo = GradleVersionInfo.fetchNightly()
|
val versionInfo = GradleVersionInfo.fetchNightly()
|
||||||
dependsOn(createCompatibilityTestTask(versionInfo))
|
dependsOn(createCompatibilityTestTask(versionInfo))
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user