diff --git a/build.gradle b/build.gradle index 7fcdd7945..51aa8fa7e 100644 --- a/build.gradle +++ b/build.gradle @@ -116,6 +116,7 @@ subprojects { project -> api "com.squareup.okhttp:okhttp-urlconnection:2.7.5" api "com.squareup.okhttp:okhttp-apache:2.7.5" api "org.jsoup:jsoup:1.15.3" //CVE-2022-36033:jinjava-2.6.0 > jsoup-1.14.2 + implementation "org.apache.ivy:ivy:2.5.2" testImplementation "org.springframework.boot:spring-boot-starter-test" @@ -123,9 +124,11 @@ subprojects { project -> testImplementation "org.spockframework:spock-spring" testImplementation "org.springframework:spring-test" testImplementation "org.hamcrest:hamcrest-core" + //testImplementation "org.apache.groovy:groovy-all" testRuntimeOnly "cglib:cglib-nodep" testRuntimeOnly "org.objenesis:objenesis" + } } diff --git a/kayenta-signalfx/kayenta-signalfx.gradle b/kayenta-signalfx/kayenta-signalfx.gradle index 2622bfa07..180f2a513 100644 --- a/kayenta-signalfx/kayenta-signalfx.gradle +++ b/kayenta-signalfx/kayenta-signalfx.gradle @@ -109,7 +109,7 @@ integrationTest { dependencies { implementation project(":kayenta-core") - api 'com.signalfx.public:signalfx-java:1.0.31' + api 'com.signalfx.public:signalfx-java:1.0.34' testImplementation 'com.tngtech.java:junit-dataprovider:1.13.1' testImplementation project(":kayenta-standalone-canary-analysis") diff --git a/kayenta-standalone-canary-analysis/src/test/java/com/netflix/kayenta/standalonecanaryanalysis/orca/stage/SetupAndExecuteCanariesStageTest.java b/kayenta-standalone-canary-analysis/src/test/java/com/netflix/kayenta/standalonecanaryanalysis/orca/stage/SetupAndExecuteCanariesStageTest.java index b51282d34..b036aa960 100644 --- a/kayenta-standalone-canary-analysis/src/test/java/com/netflix/kayenta/standalonecanaryanalysis/orca/stage/SetupAndExecuteCanariesStageTest.java +++ b/kayenta-standalone-canary-analysis/src/test/java/com/netflix/kayenta/standalonecanaryanalysis/orca/stage/SetupAndExecuteCanariesStageTest.java @@ -28,6 +28,7 @@ import java.time.Duration; import java.time.Instant; import java.time.temporal.ChronoUnit; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.mockito.Mock; @@ -77,11 +78,13 @@ public void test_that_calculateLifetime_uses_supplied_start_and_end_time_if_prov assertEquals("The duration should be 5 minutes", expected, actual); } - @Test(expected = IllegalArgumentException.class) + @Test public void test_that_calculateLifetime_throws_an_error_if_lifetime_and_start_and_endtime_not_provided() { Instant now = Instant.now(); - stage.calculateLifetime(now, null, CanaryAnalysisExecutionRequest.builder().build()); + Assertions.assertThrows( + IllegalArgumentException.class, + () -> stage.calculateLifetime(now, null, CanaryAnalysisExecutionRequest.builder().build())); } @Test