diff --git a/build.gradle b/build.gradle index 0b5ae72..ea4d630 100644 --- a/build.gradle +++ b/build.gradle @@ -41,7 +41,7 @@ dependencies { testImplementation platform("org.junit:junit-bom:5.10.1") testImplementation "org.junit.jupiter:junit-jupiter-api" testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine" - testImplementation 'org.mockito:mockito-core:4.11.0' + testImplementation 'org.mockito:mockito-core:5.9.0' } tasks.withType(Test).configureEach { diff --git a/src/test/java/com/github/boginw/mybatis_migrations/task/MigrationsTaskTest.java b/src/test/java/com/github/boginw/mybatis_migrations/task/MigrationsTaskTest.java index 7ca67eb..8d7c978 100644 --- a/src/test/java/com/github/boginw/mybatis_migrations/task/MigrationsTaskTest.java +++ b/src/test/java/com/github/boginw/mybatis_migrations/task/MigrationsTaskTest.java @@ -14,6 +14,7 @@ import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.mockito.Mock; +import org.mockito.Mockito; import org.mockito.MockitoAnnotations; import javax.annotation.OverridingMethodsMustInvokeSuper; @@ -92,7 +93,7 @@ void whenOutputProvidedAndTaskIsRun_expectPrintStreamToBeSetOnCommand() @Test void whenTaskIsRun_expectCommandToBeRun() { task.run(); - verify(command).execute(any()); + verify(command).execute(any(String[].class)); } @Test