Allow Gradle task property to be set with String or enum value

See gh-32769
This commit is contained in:
Scott Frederick
2022-10-20 13:59:54 -05:00
parent c53c8c84b8
commit b78b22b6f6
3 changed files with 19 additions and 3 deletions

View File

@@ -216,7 +216,7 @@ class BootBuildImageTests {
@Test
void whenPullPolicyIsConfiguredThenRequestHasPullPolicy() {
this.buildImage.getPullPolicy().set(PullPolicy.NEVER.toString());
this.buildImage.getPullPolicy().set(PullPolicy.NEVER);
assertThat(this.buildImage.createRequest().getPullPolicy()).isEqualTo(PullPolicy.NEVER);
}