readAllFiles(FilesWithEntryPoint reportFiles) {
@@ -147,16 +148,16 @@ public final class GcsPluginUtilsTest {
}
@Test
- public void testCreateReportFiles_destinationIsFile() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
- folder.newFolder("my", "root", "some", "path");
- File destination = folder.newFile("my/root/some/path/file.txt");
- Files.write(destination.toPath(), "some data".getBytes(UTF_8));
+ void testCreateReportFiles_destinationIsFile() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
+ Path somePath = createDirectories(root.resolve("some/path"));
+ Path destination = createFile(somePath.resolve("file.txt"));
+ Files.write(destination, "some data".getBytes(UTF_8));
// Since the entry point is obvious here - any hint given is just ignored.
- File ignoredHint = folder.newFile("my/root/ignored.txt");
+ File ignoredHint = createFile(root.resolve("ignored.txt")).toFile();
FilesWithEntryPoint files =
- readFilesWithEntryPoint(destination, Optional.of(ignoredHint), root);
+ readFilesWithEntryPoint(destination.toFile(), Optional.of(ignoredHint), root);
assertThat(files.entryPoint().toString())
.isEqualTo(filenameJoiner.join("some", "path", "file.txt"));
@@ -165,13 +166,13 @@ public final class GcsPluginUtilsTest {
}
@Test
- public void testCreateReportFiles_destinationDoesntExist() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
+ void testCreateReportFiles_destinationDoesntExist() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
File destination = root.resolve("non/existing.txt").toFile();
assertThat(destination.isFile()).isFalse();
assertThat(destination.isDirectory()).isFalse();
- // Since there are not files, any hint given is obvioulsy wrong and will be ignored.
- File ignoredHint = folder.newFile("my/root/ignored.txt");
+ // Since there are no files, any hint given is obviously wrong and will be ignored.
+ File ignoredHint = createFile(root.resolve("ignored.txt")).toFile();
FilesWithEntryPoint files =
readFilesWithEntryPoint(destination, Optional.of(ignoredHint), root);
@@ -181,34 +182,33 @@ public final class GcsPluginUtilsTest {
}
@Test
- public void testCreateReportFiles_noFiles() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
- File destination = folder.newFolder("my", "root", "some", "path");
- folder.newFolder("my", "root", "some", "path", "a", "b");
- folder.newFolder("my", "root", "some", "path", "c");
- // Since there are not files, any hint given is obvioulsy wrong and will be ignored.
- File ignoredHint = folder.newFile("my/root/ignored.txt");
+ void testCreateReportFiles_noFiles() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
+ Path destination = createDirectories(root.resolve("some/path"));
+ createDirectories(destination.resolve("a/b"));
+ createDirectory(destination.resolve("c"));
+ // Since there are not files, any hint given is obviously wrong and will be ignored.
+ File ignoredHint = createFile(root.resolve("ignored.txt")).toFile();
FilesWithEntryPoint files =
- readFilesWithEntryPoint(destination, Optional.of(ignoredHint), root);
+ readFilesWithEntryPoint(destination.toFile(), Optional.of(ignoredHint), root);
assertThat(files.entryPoint().toString()).isEqualTo(filenameJoiner.join("some", "path"));
assertThat(files.files()).isEmpty();
}
@Test
- public void testCreateReportFiles_oneFile() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
- File destination = folder.newFolder("my", "root", "some", "path");
- folder.newFolder("my", "root", "some", "path", "a", "b");
- folder.newFolder("my", "root", "some", "path", "c");
- Files.write(
- folder.newFile("my/root/some/path/a/file.txt").toPath(), "some data".getBytes(UTF_8));
+ void testCreateReportFiles_oneFile() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
+ Path destination = createDirectories(root.resolve("some/path"));
+ createDirectories(destination.resolve("a/b"));
+ createDirectory(destination.resolve("c"));
+ Files.write(createFile(destination.resolve("a/file.txt")), "some data".getBytes(UTF_8));
// Since the entry point is obvious here - any hint given is just ignored.
- File ignoredHint = folder.newFile("my/root/ignored.txt");
+ File ignoredHint = createFile(root.resolve("ignored.txt")).toFile();
FilesWithEntryPoint files =
- readFilesWithEntryPoint(destination, Optional.of(ignoredHint), root);
+ readFilesWithEntryPoint(destination.toFile(), Optional.of(ignoredHint), root);
assertThat(files.entryPoint().toString())
.isEqualTo(filenameJoiner.join("some", "path", "a", "file.txt"));
@@ -222,22 +222,19 @@ public final class GcsPluginUtilsTest {
* TODO(guyben): switch to checking zip file instead.
*/
@Test
- public void testCreateReportFiles_multipleFiles_noHint() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
- File destination = folder.newFolder("my", "root", "some", "path");
- folder.newFolder("my", "root", "some", "path", "a", "b");
- folder.newFolder("my", "root", "some", "path", "c");
+ void testCreateReportFiles_multipleFiles_noHint() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
+ Path destination = createDirectories(root.resolve("some/path"));
+ createDirectories(destination.resolve("a/b"));
+ createDirectory(destination.resolve("c"));
- Files.write(
- folder.newFile("my/root/some/path/index.html").toPath(), "some data".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/a/index.html").toPath(), "wrong index".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/c/style.css").toPath(), "css file".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/my_image.png").toPath(), "images".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("index.html")), "some data".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("a/index.html")), "wrong index".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("c/style.css")), "css file".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("my_image.png")), "images".getBytes(UTF_8));
- FilesWithEntryPoint files = readFilesWithEntryPoint(destination, Optional.empty(), root);
+ FilesWithEntryPoint files =
+ readFilesWithEntryPoint(destination.toFile(), Optional.empty(), root);
assertThat(files.entryPoint().toString())
.isEqualTo(filenameJoiner.join("some", "path", "path.zip"));
@@ -251,24 +248,20 @@ public final class GcsPluginUtilsTest {
*
TODO(guyben): switch to checking zip file instead.
*/
@Test
- public void testCreateReportFiles_multipleFiles_withBadHint() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
- File destination = folder.newFolder("my", "root", "some", "path");
+ void testCreateReportFiles_multipleFiles_withBadHint() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
+ Path destination = createDirectories(root.resolve("some/path"));
// This entry point points to a directory, which isn't an appropriate entry point
- File badEntryPoint = folder.newFolder("my", "root", "some", "path", "a", "b");
- folder.newFolder("my", "root", "some", "path", "c");
+ File badEntryPoint = createDirectories(destination.resolve("a/b")).toFile();
+ createDirectory(destination.resolve("c"));
- Files.write(
- folder.newFile("my/root/some/path/index.html").toPath(), "some data".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/a/index.html").toPath(), "wrong index".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/c/style.css").toPath(), "css file".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/my_image.png").toPath(), "images".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("index.html")), "some data".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("a/index.html")), "wrong index".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("c/style.css")), "css file".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("my_image.png")), "images".getBytes(UTF_8));
FilesWithEntryPoint files =
- readFilesWithEntryPoint(destination, Optional.of(badEntryPoint), root);
+ readFilesWithEntryPoint(destination.toFile(), Optional.of(badEntryPoint), root);
assertThat(files.entryPoint().toString())
.isEqualTo(filenameJoiner.join("some", "path", "path.zip"));
@@ -277,24 +270,21 @@ public final class GcsPluginUtilsTest {
}
@Test
- public void testCreateReportFiles_multipleFiles_withGoodHint() throws Exception {
- Path root = toNormalizedPath(folder.newFolder("my", "root"));
- File destination = folder.newFolder("my", "root", "some", "path");
- folder.newFolder("my", "root", "some", "path", "a", "b");
- folder.newFolder("my", "root", "some", "path", "c");
+ void testCreateReportFiles_multipleFiles_withGoodHint() throws Exception {
+ Path root = toNormalizedPath(createDirectories(tmpDir.resolve("my/root")).toAbsolutePath());
+ Path destination = createDirectories(root.resolve("some/path"));
+ createDirectories(destination.resolve("a/b"));
+ createDirectory(destination.resolve("c"));
// The hint is an actual file nested in the destination directory!
- File goodEntryPoint = folder.newFile("my/root/some/path/index.html");
+ Path goodEntryPoint = createFile(destination.resolve("index.html"));
- Files.write(goodEntryPoint.toPath(), "some data".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/a/index.html").toPath(), "wrong index".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/c/style.css").toPath(), "css file".getBytes(UTF_8));
- Files.write(
- folder.newFile("my/root/some/path/my_image.png").toPath(), "images".getBytes(UTF_8));
+ Files.write(goodEntryPoint, "some data".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("a/index.html")), "wrong index".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("c/style.css")), "css file".getBytes(UTF_8));
+ Files.write(createFile(destination.resolve("my_image.png")), "images".getBytes(UTF_8));
FilesWithEntryPoint files =
- readFilesWithEntryPoint(destination, Optional.of(goodEntryPoint), root);
+ readFilesWithEntryPoint(destination.toFile(), Optional.of(goodEntryPoint.toFile()), root);
assertThat(files.entryPoint().toString())
.isEqualTo(filenameJoiner.join("some", "path", "index.html"));
diff --git a/common/build.gradle b/common/build.gradle
index 7b629e9d3..de7d2d495 100644
--- a/common/build.gradle
+++ b/common/build.gradle
@@ -61,8 +61,6 @@ dependencies {
testingCompile deps['com.google.truth:truth']
testingCompile deps['io.github.java-diff-utils:java-diff-utils']
- testCompile deps['junit:junit']
testCompile deps['org.junit.jupiter:junit-jupiter-api']
testCompile deps['org.junit.jupiter:junit-jupiter-engine']
- testCompile deps['org.junit.vintage:junit-vintage-engine']
}
diff --git a/common/gradle/dependency-locks/testCompile.lockfile b/common/gradle/dependency-locks/testCompile.lockfile
index 8cdc81ffa..e4b450b46 100644
--- a/common/gradle/dependency-locks/testCompile.lockfile
+++ b/common/gradle/dependency-locks/testCompile.lockfile
@@ -14,7 +14,7 @@ com.googlecode.java-diff-utils:diffutils:1.3.0
io.github.java-diff-utils:java-diff-utils:4.0
javax.inject:javax.inject:1
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apiguardian:apiguardian-api:1.1.0
org.checkerframework:checker-compat-qual:2.5.5
org.checkerframework:checker-qual:2.11.1
@@ -24,6 +24,5 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
diff --git a/common/gradle/dependency-locks/testCompileClasspath.lockfile b/common/gradle/dependency-locks/testCompileClasspath.lockfile
index 8cdc81ffa..e4b450b46 100644
--- a/common/gradle/dependency-locks/testCompileClasspath.lockfile
+++ b/common/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -14,7 +14,7 @@ com.googlecode.java-diff-utils:diffutils:1.3.0
io.github.java-diff-utils:java-diff-utils:4.0
javax.inject:javax.inject:1
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apiguardian:apiguardian-api:1.1.0
org.checkerframework:checker-compat-qual:2.5.5
org.checkerframework:checker-qual:2.11.1
@@ -24,6 +24,5 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
diff --git a/common/gradle/dependency-locks/testRuntime.lockfile b/common/gradle/dependency-locks/testRuntime.lockfile
index 1cf05bf4f..56ba0f311 100644
--- a/common/gradle/dependency-locks/testRuntime.lockfile
+++ b/common/gradle/dependency-locks/testRuntime.lockfile
@@ -15,7 +15,7 @@ com.googlecode.java-diff-utils:diffutils:1.3.0
io.github.java-diff-utils:java-diff-utils:4.0
javax.inject:javax.inject:1
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apiguardian:apiguardian-api:1.1.0
org.checkerframework:checker-compat-qual:2.5.5
org.checkerframework:checker-qual:2.11.1
@@ -25,6 +25,5 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
diff --git a/common/gradle/dependency-locks/testRuntimeClasspath.lockfile b/common/gradle/dependency-locks/testRuntimeClasspath.lockfile
index 1cf05bf4f..56ba0f311 100644
--- a/common/gradle/dependency-locks/testRuntimeClasspath.lockfile
+++ b/common/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -15,7 +15,7 @@ com.googlecode.java-diff-utils:diffutils:1.3.0
io.github.java-diff-utils:java-diff-utils:4.0
javax.inject:javax.inject:1
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apiguardian:apiguardian-api:1.1.0
org.checkerframework:checker-compat-qual:2.5.5
org.checkerframework:checker-qual:2.11.1
@@ -25,6 +25,5 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
diff --git a/common/src/test/java/google/registry/testing/truth/TextDiffSubjectTest.java b/common/src/test/java/google/registry/testing/truth/TextDiffSubjectTest.java
index 67a8c27a5..fcb9064bd 100644
--- a/common/src/test/java/google/registry/testing/truth/TextDiffSubjectTest.java
+++ b/common/src/test/java/google/registry/testing/truth/TextDiffSubjectTest.java
@@ -17,7 +17,7 @@ package google.registry.testing.truth;
import static com.google.common.io.Resources.getResource;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.truth.TextDiffSubject.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Joiner;
import com.google.common.collect.ImmutableList;
@@ -25,13 +25,10 @@ import com.google.common.io.Resources;
import google.registry.testing.truth.TextDiffSubject.DiffFormat;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link TextDiffSubject}. */
-@RunWith(JUnit4.class)
-public class TextDiffSubjectTest {
+class TextDiffSubjectTest {
private static final String RESOURCE_FOLDER = "google/registry/testing/truth/";
// Resources for input data.
@@ -44,21 +41,21 @@ public class TextDiffSubjectTest {
RESOURCE_FOLDER + "text-sidebyside-diff.txt";
@Test
- public void unifiedDiff_equal() throws IOException {
+ void unifiedDiff_equal() throws IOException {
assertThat(getResource(ACTUAL_RESOURCE))
.withDiffFormat(DiffFormat.UNIFIED_DIFF)
.hasSameContentAs(getResource(ACTUAL_RESOURCE));
}
@Test
- public void sideBySideDiff_equal() throws IOException {
+ void sideBySideDiff_equal() throws IOException {
assertThat(getResource(ACTUAL_RESOURCE))
.withDiffFormat(DiffFormat.SIDE_BY_SIDE_MARKDOWN)
.hasSameContentAs(getResource(ACTUAL_RESOURCE));
}
@Test
- public void unifedDiff_notEqual() throws IOException {
+ void unifedDiff_notEqual() throws IOException {
assertThrows(
AssertionError.class,
() ->
@@ -68,7 +65,7 @@ public class TextDiffSubjectTest {
}
@Test
- public void sideBySideDiff_notEqual() throws IOException {
+ void sideBySideDiff_notEqual() throws IOException {
assertThrows(
AssertionError.class,
() ->
@@ -78,13 +75,13 @@ public class TextDiffSubjectTest {
}
@Test
- public void displayed_unifiedDiff_noDiff() throws IOException {
+ void displayed_unifiedDiff_noDiff() throws IOException {
ImmutableList actual = readAllLinesFromResource(ACTUAL_RESOURCE);
assertThat(TextDiffSubject.generateUnifiedDiff(actual, actual)).isEqualTo("");
}
@Test
- public void displayed_unifiedDiff_hasDiff() throws IOException {
+ void displayed_unifiedDiff_hasDiff() throws IOException {
ImmutableList actual = readAllLinesFromResource(ACTUAL_RESOURCE);
ImmutableList expected = readAllLinesFromResource(EXPECTED_RESOURCE);
String diff = Joiner.on('\n').join(readAllLinesFromResource(UNIFIED_DIFF_RESOURCE));
@@ -92,7 +89,7 @@ public class TextDiffSubjectTest {
}
@Test
- public void displayed_sideBySideDiff_hasDiff() throws IOException {
+ void displayed_sideBySideDiff_hasDiff() throws IOException {
ImmutableList actual = readAllLinesFromResource(ACTUAL_RESOURCE);
ImmutableList expected = readAllLinesFromResource(EXPECTED_RESOURCE);
String diff = Joiner.on('\n').join(readAllLinesFromResource(SIDE_BY_SIDE_DIFF_RESOURCE));
diff --git a/core/src/test/java/google/registry/backup/GcsDiffFileListerTest.java b/core/src/test/java/google/registry/backup/GcsDiffFileListerTest.java
index adb27af4b..bd9ae256d 100644
--- a/core/src/test/java/google/registry/backup/GcsDiffFileListerTest.java
+++ b/core/src/test/java/google/registry/backup/GcsDiffFileListerTest.java
@@ -21,8 +21,8 @@ import static google.registry.backup.BackupUtils.GcsMetadataKeys.LOWER_BOUND_CHE
import static google.registry.backup.ExportCommitLogDiffAction.DIFF_FILE_PREFIX;
import static java.lang.reflect.Proxy.newProxyInstance;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
-import static org.junit.Assert.fail;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assertions.fail;
import com.google.appengine.tools.cloudstorage.GcsFileMetadata;
import com.google.appengine.tools.cloudstorage.GcsFileOptions;
diff --git a/core/src/test/java/google/registry/batch/AsyncTaskEnqueuerTest.java b/core/src/test/java/google/registry/batch/AsyncTaskEnqueuerTest.java
index e3f160044..6dad3e8be 100644
--- a/core/src/test/java/google/registry/batch/AsyncTaskEnqueuerTest.java
+++ b/core/src/test/java/google/registry/batch/AsyncTaskEnqueuerTest.java
@@ -31,7 +31,7 @@ import static google.registry.testing.TestLogHandlerUtils.assertLogMessage;
import static org.joda.time.Duration.standardDays;
import static org.joda.time.Duration.standardHours;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.when;
import com.google.common.collect.ImmutableSortedSet;
diff --git a/core/src/test/java/google/registry/batch/DeleteProberDataActionTest.java b/core/src/test/java/google/registry/batch/DeleteProberDataActionTest.java
index 0153110b4..ab94bab10 100644
--- a/core/src/test/java/google/registry/batch/DeleteProberDataActionTest.java
+++ b/core/src/test/java/google/registry/batch/DeleteProberDataActionTest.java
@@ -30,7 +30,7 @@ import static google.registry.testing.TaskQueueHelper.assertDnsTasksEnqueued;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.googlecode.objectify.Key;
diff --git a/core/src/test/java/google/registry/batch/ExpandRecurringBillingEventsActionTest.java b/core/src/test/java/google/registry/batch/ExpandRecurringBillingEventsActionTest.java
index 5ff99ef53..ffa96ce92 100644
--- a/core/src/test/java/google/registry/batch/ExpandRecurringBillingEventsActionTest.java
+++ b/core/src/test/java/google/registry/batch/ExpandRecurringBillingEventsActionTest.java
@@ -31,7 +31,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/beam/BeamUtilsTest.java b/core/src/test/java/google/registry/beam/BeamUtilsTest.java
index e01349cea..f30cfd49c 100644
--- a/core/src/test/java/google/registry/beam/BeamUtilsTest.java
+++ b/core/src/test/java/google/registry/beam/BeamUtilsTest.java
@@ -15,7 +15,7 @@
package google.registry.beam;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import org.apache.avro.Schema;
diff --git a/core/src/test/java/google/registry/beam/TestPipelineExtension.java b/core/src/test/java/google/registry/beam/TestPipelineExtension.java
index 94441733d..c96141a3e 100644
--- a/core/src/test/java/google/registry/beam/TestPipelineExtension.java
+++ b/core/src/test/java/google/registry/beam/TestPipelineExtension.java
@@ -27,9 +27,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.common.base.Strings;
import com.google.common.collect.Maps;
import java.io.IOException;
-import java.lang.annotation.Annotation;
import java.util.ArrayList;
-import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.Optional;
@@ -59,7 +57,6 @@ import org.apache.beam.sdk.testing.TestPipelineOptions;
import org.apache.beam.sdk.testing.ValidatesRunner;
import org.apache.beam.sdk.transforms.SerializableFunction;
import org.apache.beam.sdk.util.common.ReflectHelpers;
-import org.junit.experimental.categories.Category;
import org.junit.jupiter.api.extension.AfterEachCallback;
import org.junit.jupiter.api.extension.BeforeEachCallback;
import org.junit.jupiter.api.extension.ExtensionContext;
@@ -89,11 +86,10 @@ import org.junit.jupiter.api.extension.ExtensionContext;
* remote execution modes. For example:
*
*
- * {@literal @Rule}
- * public final transient TestPipeline p = TestPipeline.create();
+ * {@literal @RegisterExtension}
+ * final transient TestPipeline p = TestPipeline.create();
*
* {@literal @Test}
- * {@literal @Category}(NeedsRunner.class)
* public void myPipelineTest() throws Exception {
* final PCollection<String> pCollection = pipeline.apply(...)
* PAssert.that(pCollection).containsInAnyOrder(...);
@@ -119,17 +115,17 @@ public class TestPipelineExtension extends Pipeline
protected final Pipeline pipeline;
- protected boolean runAttempted;
+ boolean runAttempted;
private PipelineRunEnforcement(final Pipeline pipeline) {
this.pipeline = pipeline;
}
- protected void enableAutoRunIfMissing(final boolean enable) {
+ void enableAutoRunIfMissing(final boolean enable) {
enableAutoRunIfMissing = enable;
}
- protected void beforePipelineExecution() {
+ void beforePipelineExecution() {
runAttempted = true;
}
@@ -248,9 +244,9 @@ public class TestPipelineExtension extends Pipeline
}
/** System property used to set {@link TestPipelineOptions}. */
- public static final String PROPERTY_BEAM_TEST_PIPELINE_OPTIONS = "beamTestPipelineOptions";
+ private static final String PROPERTY_BEAM_TEST_PIPELINE_OPTIONS = "beamTestPipelineOptions";
- static final String PROPERTY_USE_DEFAULT_DUMMY_RUNNER = "beamUseDummyRunner";
+ private static final String PROPERTY_USE_DEFAULT_DUMMY_RUNNER = "beamUseDummyRunner";
private static final ObjectMapper MAPPER =
new ObjectMapper()
@@ -332,8 +328,9 @@ public class TestPipelineExtension extends Pipeline
public PipelineResult run(PipelineOptions options) {
checkState(
enforcement.isPresent(),
- "Is your TestPipeline declaration missing a @Rule annotation? Usage: "
- + "@Rule public final transient TestPipeline pipeline = TestPipeline.create();");
+ "Is your TestPipeline declaration missing a @RegisterExtension annotation? Usage:"
+ + " @RegisterExtension final transient TestPipelineExtension pipeline ="
+ + " TestPipeline.create();");
final PipelineResult pipelineResult;
try {
@@ -434,7 +431,7 @@ public class TestPipelineExtension extends Pipeline
}
/** Creates {@link PipelineOptions} for testing. */
- public static PipelineOptions testingPipelineOptions() {
+ private static PipelineOptions testingPipelineOptions() {
try {
@Nullable
String beamTestPipelineOptions = System.getProperty(PROPERTY_BEAM_TEST_PIPELINE_OPTIONS);
@@ -474,7 +471,7 @@ public class TestPipelineExtension extends Pipeline
* Note this only runs for runners which support Metrics. Runners which do not should verify
* this in some other way. See: https://issues.apache.org/jira/browse/BEAM-2001
*/
- public static void verifyPAssertsSucceeded(Pipeline pipeline, PipelineResult pipelineResult) {
+ private static void verifyPAssertsSucceeded(Pipeline pipeline, PipelineResult pipelineResult) {
if (MetricsEnvironment.isMetricsSupported()) {
long expectedNumberOfAssertions = (long) PAssert.countAsserts(pipeline);
@@ -514,29 +511,4 @@ public class TestPipelineExtension extends Pipeline
empty = false;
}
}
-
- /**
- * A utility class for querying annotations.
- *
- *
NOTE: This was copied from the Apache Beam project from a separate file only for visibility
- * reasons (it's package-private there).
- */
- static class Annotations {
-
- /** Annotation predicates. */
- static class Predicates {
-
- static Predicate isAnnotationOfType(final Class extends Annotation> clazz) {
- return annotation ->
- annotation.annotationType() != null && annotation.annotationType().equals(clazz);
- }
-
- static Predicate isCategoryOf(final Class> value, final boolean allowDerived) {
- return category ->
- Arrays.stream(((Category) category).value())
- .anyMatch(
- aClass -> allowDerived ? value.isAssignableFrom(aClass) : value.equals(aClass));
- }
- }
- }
}
diff --git a/core/src/test/java/google/registry/beam/initsql/DomainBaseUtilTest.java b/core/src/test/java/google/registry/beam/initsql/DomainBaseUtilTest.java
index abe47221b..5b6f027a7 100644
--- a/core/src/test/java/google/registry/beam/initsql/DomainBaseUtilTest.java
+++ b/core/src/test/java/google/registry/beam/initsql/DomainBaseUtilTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.cloneAndSetAutoTimestamps;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.api.datastore.Entity;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/beam/invoicing/BillingEventTest.java b/core/src/test/java/google/registry/beam/invoicing/BillingEventTest.java
index c46683cdf..7366e9050 100644
--- a/core/src/test/java/google/registry/beam/invoicing/BillingEventTest.java
+++ b/core/src/test/java/google/registry/beam/invoicing/BillingEventTest.java
@@ -15,7 +15,7 @@
package google.registry.beam.invoicing;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.beam.invoicing.BillingEvent.InvoiceGroupingKey;
import google.registry.beam.invoicing.BillingEvent.InvoiceGroupingKey.InvoiceGroupingKeyCoder;
diff --git a/core/src/test/java/google/registry/bigquery/BigqueryUtilsTest.java b/core/src/test/java/google/registry/bigquery/BigqueryUtilsTest.java
index bf92a3cfc..434f6d8da 100644
--- a/core/src/test/java/google/registry/bigquery/BigqueryUtilsTest.java
+++ b/core/src/test/java/google/registry/bigquery/BigqueryUtilsTest.java
@@ -21,7 +21,7 @@ import static google.registry.bigquery.BigqueryUtils.toBigqueryTimestampString;
import static google.registry.bigquery.BigqueryUtils.toJobReferenceString;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.api.services.bigquery.model.JobReference;
import java.util.concurrent.TimeUnit;
diff --git a/core/src/test/java/google/registry/cron/TldFanoutActionTest.java b/core/src/test/java/google/registry/cron/TldFanoutActionTest.java
index 78d5d010e..434470639 100644
--- a/core/src/test/java/google/registry/cron/TldFanoutActionTest.java
+++ b/core/src/test/java/google/registry/cron/TldFanoutActionTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.TaskQueueHelper.assertNoTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.api.taskqueue.dev.QueueStateInfo.TaskStateInfo;
import com.google.appengine.tools.development.testing.LocalTaskQueueTestConfig;
diff --git a/core/src/test/java/google/registry/dns/DnsInjectionTest.java b/core/src/test/java/google/registry/dns/DnsInjectionTest.java
index c2141b8c9..ced7bd701 100644
--- a/core/src/test/java/google/registry/dns/DnsInjectionTest.java
+++ b/core/src/test/java/google/registry/dns/DnsInjectionTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistActiveSubordinateHost;
import static google.registry.testing.TaskQueueHelper.assertDnsTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertNoDnsTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/dns/DnsQueueTest.java b/core/src/test/java/google/registry/dns/DnsQueueTest.java
index 3e6e751b7..538c12821 100644
--- a/core/src/test/java/google/registry/dns/DnsQueueTest.java
+++ b/core/src/test/java/google/registry/dns/DnsQueueTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.TaskQueueHelper.assertNoTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.testing.AppEngineExtension;
import google.registry.testing.FakeClock;
diff --git a/core/src/test/java/google/registry/dns/PublishDnsUpdatesActionTest.java b/core/src/test/java/google/registry/dns/PublishDnsUpdatesActionTest.java
index d45f700cd..6adf0602e 100644
--- a/core/src/test/java/google/registry/dns/PublishDnsUpdatesActionTest.java
+++ b/core/src/test/java/google/registry/dns/PublishDnsUpdatesActionTest.java
@@ -19,7 +19,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistActiveSubordinateHost;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.mock;
diff --git a/core/src/test/java/google/registry/dns/RefreshDnsActionTest.java b/core/src/test/java/google/registry/dns/RefreshDnsActionTest.java
index d1b3de277..1f7e6c568 100644
--- a/core/src/test/java/google/registry/dns/RefreshDnsActionTest.java
+++ b/core/src/test/java/google/registry/dns/RefreshDnsActionTest.java
@@ -19,7 +19,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistActiveSubordinateHost;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/core/src/test/java/google/registry/dns/writer/BaseDnsWriterTest.java b/core/src/test/java/google/registry/dns/writer/BaseDnsWriterTest.java
index 5618821bc..6e479510e 100644
--- a/core/src/test/java/google/registry/dns/writer/BaseDnsWriterTest.java
+++ b/core/src/test/java/google/registry/dns/writer/BaseDnsWriterTest.java
@@ -15,7 +15,7 @@
package google.registry.dns.writer;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsMessageTransportTest.java b/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsMessageTransportTest.java
index c5813c794..506e08088 100644
--- a/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsMessageTransportTest.java
+++ b/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsMessageTransportTest.java
@@ -16,7 +16,7 @@ package google.registry.dns.writer.dnsupdate;
import static com.google.common.io.BaseEncoding.base16;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsUpdateWriterTest.java b/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsUpdateWriterTest.java
index 2b1217afd..ea6dc859a 100644
--- a/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsUpdateWriterTest.java
+++ b/core/src/test/java/google/registry/dns/writer/dnsupdate/DnsUpdateWriterTest.java
@@ -26,7 +26,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveSubordinateHo
import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistDeletedHost;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoInteractions;
diff --git a/core/src/test/java/google/registry/export/BigqueryPollJobActionTest.java b/core/src/test/java/google/registry/export/BigqueryPollJobActionTest.java
index 8029eea37..35a6f200b 100644
--- a/core/src/test/java/google/registry/export/BigqueryPollJobActionTest.java
+++ b/core/src/test/java/google/registry/export/BigqueryPollJobActionTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.TestLogHandlerUtils.assertLogMessage;
import static java.nio.charset.StandardCharsets.UTF_8;
import static java.util.logging.Level.INFO;
import static java.util.logging.Level.SEVERE;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/export/CheckBackupActionTest.java b/core/src/test/java/google/registry/export/CheckBackupActionTest.java
index 670b85adb..5f532eba0 100644
--- a/core/src/test/java/google/registry/export/CheckBackupActionTest.java
+++ b/core/src/test/java/google/registry/export/CheckBackupActionTest.java
@@ -19,7 +19,7 @@ import static google.registry.export.CheckBackupAction.CHECK_BACKUP_KINDS_TO_LOA
import static google.registry.export.CheckBackupAction.CHECK_BACKUP_NAME_PARAM;
import static google.registry.testing.TaskQueueHelper.assertNoTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/export/ExportDomainListsActionTest.java b/core/src/test/java/google/registry/export/ExportDomainListsActionTest.java
index ef6b723b9..2a40b1658 100644
--- a/core/src/test/java/google/registry/export/ExportDomainListsActionTest.java
+++ b/core/src/test/java/google/registry/export/ExportDomainListsActionTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.GcsTestingUtils.readGcsFile;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/export/ExportPremiumTermsActionTest.java b/core/src/test/java/google/registry/export/ExportPremiumTermsActionTest.java
index 44f5bd91e..a24cbc55d 100644
--- a/core/src/test/java/google/registry/export/ExportPremiumTermsActionTest.java
+++ b/core/src/test/java/google/registry/export/ExportPremiumTermsActionTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static java.nio.charset.StandardCharsets.UTF_8;
import static javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
import static javax.servlet.http.HttpServletResponse.SC_OK;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.eq;
diff --git a/core/src/test/java/google/registry/export/ExportReservedTermsActionTest.java b/core/src/test/java/google/registry/export/ExportReservedTermsActionTest.java
index f1ae8f1a1..8b6c54927 100644
--- a/core/src/test/java/google/registry/export/ExportReservedTermsActionTest.java
+++ b/core/src/test/java/google/registry/export/ExportReservedTermsActionTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static java.nio.charset.StandardCharsets.UTF_8;
import static javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
import static javax.servlet.http.HttpServletResponse.SC_OK;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.Mockito.mock;
diff --git a/core/src/test/java/google/registry/export/UpdateSnapshotViewActionTest.java b/core/src/test/java/google/registry/export/UpdateSnapshotViewActionTest.java
index 9fd95affd..a52a9dd62 100644
--- a/core/src/test/java/google/registry/export/UpdateSnapshotViewActionTest.java
+++ b/core/src/test/java/google/registry/export/UpdateSnapshotViewActionTest.java
@@ -23,7 +23,7 @@ import static google.registry.export.UpdateSnapshotViewAction.UPDATE_SNAPSHOT_TA
import static google.registry.export.UpdateSnapshotViewAction.UPDATE_SNAPSHOT_VIEWNAME_PARAM;
import static google.registry.export.UpdateSnapshotViewAction.createViewUpdateTask;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.eq;
diff --git a/core/src/test/java/google/registry/export/UploadDatastoreBackupActionTest.java b/core/src/test/java/google/registry/export/UploadDatastoreBackupActionTest.java
index 94b1f9f57..d8c9fce4f 100644
--- a/core/src/test/java/google/registry/export/UploadDatastoreBackupActionTest.java
+++ b/core/src/test/java/google/registry/export/UploadDatastoreBackupActionTest.java
@@ -26,7 +26,7 @@ import static google.registry.export.UploadDatastoreBackupAction.UPLOAD_BACKUP_K
import static google.registry.export.UploadDatastoreBackupAction.enqueueUploadBackupTask;
import static google.registry.export.UploadDatastoreBackupAction.getBackupInfoFileForKind;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.mock;
diff --git a/core/src/test/java/google/registry/export/datastore/EntityFilterTest.java b/core/src/test/java/google/registry/export/datastore/EntityFilterTest.java
index a3dcfb64a..b91a6e48d 100644
--- a/core/src/test/java/google/registry/export/datastore/EntityFilterTest.java
+++ b/core/src/test/java/google/registry/export/datastore/EntityFilterTest.java
@@ -15,7 +15,7 @@
package google.registry.export.datastore;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.api.client.json.JsonFactory;
import com.google.api.client.json.jackson2.JacksonFactory;
diff --git a/core/src/test/java/google/registry/flows/ExtensionManagerTest.java b/core/src/test/java/google/registry/flows/ExtensionManagerTest.java
index 6b140af67..c9b13b92e 100644
--- a/core/src/test/java/google/registry/flows/ExtensionManagerTest.java
+++ b/core/src/test/java/google/registry/flows/ExtensionManagerTest.java
@@ -16,7 +16,7 @@ package google.registry.flows;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/ResourceFlowTestCase.java b/core/src/test/java/google/registry/flows/ResourceFlowTestCase.java
index 213c2bc72..c37daaf38 100644
--- a/core/src/test/java/google/registry/flows/ResourceFlowTestCase.java
+++ b/core/src/test/java/google/registry/flows/ResourceFlowTestCase.java
@@ -22,7 +22,7 @@ import static google.registry.model.tmch.ClaimsListShardTest.createTestClaimsLis
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.testing.LogsSubject.assertAboutLogs;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/flows/TlsCredentialsTest.java b/core/src/test/java/google/registry/flows/TlsCredentialsTest.java
index 91a3e3629..aeb46e38a 100644
--- a/core/src/test/java/google/registry/flows/TlsCredentialsTest.java
+++ b/core/src/test/java/google/registry/flows/TlsCredentialsTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactCheckFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactCheckFlowTest.java
index 75e51f296..df5c1255e 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactCheckFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactCheckFlowTest.java
@@ -18,7 +18,7 @@ import static google.registry.model.eppoutput.CheckData.ContactCheck.create;
import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistDeletedContact;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceCheckFlowTestCase;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactCreateFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactCreateFlowTest.java
index 2bfbbbf33..5faa96cd9 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactCreateFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactCreateFlowTest.java
@@ -22,7 +22,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistDeletedContact;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowTestCase;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactDeleteFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactDeleteFlowTest.java
index b880385cf..2ebfed2f7 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactDeleteFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactDeleteFlowTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistDeletedContact;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import google.registry.flows.EppException;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactInfoFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactInfoFlowTest.java
index 6bfb9f14f..e60ef200d 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactInfoFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactInfoFlowTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactTransferApproveFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactTransferApproveFlowTest.java
index 7b49c9847..635bf7bcb 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactTransferApproveFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactTransferApproveFlowTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.getOnlyPollMessage;
import static google.registry.testing.DatastoreHelper.getPollMessages;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowUtils.BadAuthInfoForResourceException;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactTransferCancelFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactTransferCancelFlowTest.java
index ffc810770..0265e0106 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactTransferCancelFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactTransferCancelFlowTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.getOnlyPollMessage;
import static google.registry.testing.DatastoreHelper.getPollMessages;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowUtils.BadAuthInfoForResourceException;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactTransferQueryFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactTransferQueryFlowTest.java
index 1b5f7eec7..c7f984e8a 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactTransferQueryFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactTransferQueryFlowTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.assertNoBillingEvents;
import static google.registry.testing.DatastoreHelper.deleteResource;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowUtils.BadAuthInfoForResourceException;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactTransferRejectFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactTransferRejectFlowTest.java
index 621e5d4f8..45eaf3938 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactTransferRejectFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactTransferRejectFlowTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.getOnlyPollMessage;
import static google.registry.testing.DatastoreHelper.getPollMessages;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowUtils.BadAuthInfoForResourceException;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactTransferRequestFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactTransferRequestFlowTest.java
index 8b516d22b..209c08c44 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactTransferRequestFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactTransferRequestFlowTest.java
@@ -29,7 +29,7 @@ import static google.registry.testing.DatastoreHelper.getPollMessages;
import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.Iterables;
diff --git a/core/src/test/java/google/registry/flows/contact/ContactUpdateFlowTest.java b/core/src/test/java/google/registry/flows/contact/ContactUpdateFlowTest.java
index 99ce67f1f..3ad772363 100644
--- a/core/src/test/java/google/registry/flows/contact/ContactUpdateFlowTest.java
+++ b/core/src/test/java/google/registry/flows/contact/ContactUpdateFlowTest.java
@@ -22,7 +22,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistDeletedContact;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainCheckFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainCheckFlowTest.java
index 34c8f55dc..380ffc2c7 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainCheckFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainCheckFlowTest.java
@@ -31,7 +31,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Strings;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainClaimsCheckFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainClaimsCheckFlowTest.java
index 07bed9929..c4bd4d428 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainClaimsCheckFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainClaimsCheckFlowTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainCreateFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainCreateFlowTest.java
index 2349b7509..3f2ff2abd 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainCreateFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainCreateFlowTest.java
@@ -60,7 +60,7 @@ import static google.registry.tmch.LordnTaskUtils.QUEUE_SUNRISE;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Strings;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainDeleteFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainDeleteFlowTest.java
index ee29fbe08..ae301f543 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainDeleteFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainDeleteFlowTest.java
@@ -57,7 +57,7 @@ import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
import static org.joda.time.Duration.standardDays;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainFlowUtilsTest.java b/core/src/test/java/google/registry/flows/domain/DomainFlowUtilsTest.java
index a8e0d108c..9cf47aecc 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainFlowUtilsTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainFlowUtilsTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowTestCase;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainInfoFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainInfoFlowTest.java
index 295666fc6..8a90e1889 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainInfoFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainInfoFlowTest.java
@@ -27,7 +27,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.testing.TestDataHelper.updateSubstitutions;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Predicates;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainRenewFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainRenewFlowTest.java
index ba981aaa1..58048f522 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainRenewFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainRenewFlowTest.java
@@ -33,7 +33,7 @@ import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.EUR;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainRestoreRequestFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainRestoreRequestFlowTest.java
index b74221a00..eb553f4b4 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainRestoreRequestFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainRestoreRequestFlowTest.java
@@ -33,7 +33,7 @@ import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.EUR;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainTransferApproveFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainTransferApproveFlowTest.java
index f8639e888..53d91fd35 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainTransferApproveFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainTransferApproveFlowTest.java
@@ -35,7 +35,7 @@ import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptio
import static google.registry.testing.HistoryEntrySubject.assertAboutHistoryEntries;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainTransferCancelFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainTransferCancelFlowTest.java
index 1587906e7..b6eec79ab 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainTransferCancelFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainTransferCancelFlowTest.java
@@ -31,7 +31,7 @@ import static google.registry.testing.DomainBaseSubject.assertAboutDomains;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.testing.HistoryEntrySubject.assertAboutHistoryEntries;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainTransferQueryFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainTransferQueryFlowTest.java
index fba20af6c..0c6621bf6 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainTransferQueryFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainTransferQueryFlowTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.getPollMessages;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DomainBaseSubject.assertAboutDomains;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceFlowUtils.BadAuthInfoForResourceException;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainTransferRejectFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainTransferRejectFlowTest.java
index d4dbdc104..f27dbe369 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainTransferRejectFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainTransferRejectFlowTest.java
@@ -33,7 +33,7 @@ import static google.registry.testing.DomainBaseSubject.assertAboutDomains;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.testing.HistoryEntrySubject.assertAboutHistoryEntries;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import google.registry.flows.EppException;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainTransferRequestFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainTransferRequestFlowTest.java
index ecb2cd475..a5b472b49 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainTransferRequestFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainTransferRequestFlowTest.java
@@ -46,7 +46,7 @@ import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Predicates;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/flows/domain/DomainUpdateFlowTest.java b/core/src/test/java/google/registry/flows/domain/DomainUpdateFlowTest.java
index d2d115ce9..c0baae2ad 100644
--- a/core/src/test/java/google/registry/flows/domain/DomainUpdateFlowTest.java
+++ b/core/src/test/java/google/registry/flows/domain/DomainUpdateFlowTest.java
@@ -39,7 +39,7 @@ import static google.registry.testing.HistoryEntrySubject.assertAboutHistoryEntr
import static google.registry.testing.TaskQueueHelper.assertDnsTasksEnqueued;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/flows/domain/token/AllocationTokenFlowUtilsTest.java b/core/src/test/java/google/registry/flows/domain/token/AllocationTokenFlowUtilsTest.java
index 003ec2097..ea39cfdcd 100644
--- a/core/src/test/java/google/registry/flows/domain/token/AllocationTokenFlowUtilsTest.java
+++ b/core/src/test/java/google/registry/flows/domain/token/AllocationTokenFlowUtilsTest.java
@@ -26,7 +26,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/flows/host/HostCheckFlowTest.java b/core/src/test/java/google/registry/flows/host/HostCheckFlowTest.java
index 2d91d4c32..231fe090a 100644
--- a/core/src/test/java/google/registry/flows/host/HostCheckFlowTest.java
+++ b/core/src/test/java/google/registry/flows/host/HostCheckFlowTest.java
@@ -18,7 +18,7 @@ import static google.registry.model.eppoutput.CheckData.HostCheck.create;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistDeletedHost;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.ResourceCheckFlowTestCase;
diff --git a/core/src/test/java/google/registry/flows/host/HostCreateFlowTest.java b/core/src/test/java/google/registry/flows/host/HostCreateFlowTest.java
index 051e0d9ea..da04c5f84 100644
--- a/core/src/test/java/google/registry/flows/host/HostCreateFlowTest.java
+++ b/core/src/test/java/google/registry/flows/host/HostCreateFlowTest.java
@@ -29,7 +29,7 @@ import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptio
import static google.registry.testing.HostResourceSubject.assertAboutHosts;
import static google.registry.testing.TaskQueueHelper.assertDnsTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertNoDnsTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Strings;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/flows/host/HostDeleteFlowTest.java b/core/src/test/java/google/registry/flows/host/HostDeleteFlowTest.java
index 40019e865..d1f559492 100644
--- a/core/src/test/java/google/registry/flows/host/HostDeleteFlowTest.java
+++ b/core/src/test/java/google/registry/flows/host/HostDeleteFlowTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static google.registry.testing.HostResourceSubject.assertAboutHosts;
import static google.registry.testing.TaskQueueHelper.assertNoDnsTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/host/HostFlowUtilsTest.java b/core/src/test/java/google/registry/flows/host/HostFlowUtilsTest.java
index daab02625..4f8caaa50 100644
--- a/core/src/test/java/google/registry/flows/host/HostFlowUtilsTest.java
+++ b/core/src/test/java/google/registry/flows/host/HostFlowUtilsTest.java
@@ -16,7 +16,7 @@ package google.registry.flows.host;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.flows.host.HostFlowUtils.validateHostName;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Strings;
import google.registry.flows.host.HostFlowUtils.HostNameNotLowerCaseException;
diff --git a/core/src/test/java/google/registry/flows/host/HostInfoFlowTest.java b/core/src/test/java/google/registry/flows/host/HostInfoFlowTest.java
index b8aed6545..43711e57b 100644
--- a/core/src/test/java/google/registry/flows/host/HostInfoFlowTest.java
+++ b/core/src/test/java/google/registry/flows/host/HostInfoFlowTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/flows/host/HostUpdateFlowTest.java b/core/src/test/java/google/registry/flows/host/HostUpdateFlowTest.java
index 07c86cc11..ffded821c 100644
--- a/core/src/test/java/google/registry/flows/host/HostUpdateFlowTest.java
+++ b/core/src/test/java/google/registry/flows/host/HostUpdateFlowTest.java
@@ -38,7 +38,7 @@ import static google.registry.testing.TaskQueueHelper.assertDnsTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertNoDnsTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Strings;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/flows/poll/PollAckFlowTest.java b/core/src/test/java/google/registry/flows/poll/PollAckFlowTest.java
index e29923524..f26fafe7f 100644
--- a/core/src/test/java/google/registry/flows/poll/PollAckFlowTest.java
+++ b/core/src/test/java/google/registry/flows/poll/PollAckFlowTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import google.registry.flows.FlowTestCase;
diff --git a/core/src/test/java/google/registry/flows/poll/PollRequestFlowTest.java b/core/src/test/java/google/registry/flows/poll/PollRequestFlowTest.java
index 71f24ac07..c199f20cc 100644
--- a/core/src/test/java/google/registry/flows/poll/PollRequestFlowTest.java
+++ b/core/src/test/java/google/registry/flows/poll/PollRequestFlowTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.flows.EppException;
diff --git a/core/src/test/java/google/registry/flows/session/HelloFlowTest.java b/core/src/test/java/google/registry/flows/session/HelloFlowTest.java
index cb9ff530a..bfb5f82a0 100644
--- a/core/src/test/java/google/registry/flows/session/HelloFlowTest.java
+++ b/core/src/test/java/google/registry/flows/session/HelloFlowTest.java
@@ -16,7 +16,7 @@ package google.registry.flows.session;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
import static org.joda.time.format.ISODateTimeFormat.dateTimeNoMillis;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import google.registry.flows.EppException;
diff --git a/core/src/test/java/google/registry/flows/session/LoginFlowTestCase.java b/core/src/test/java/google/registry/flows/session/LoginFlowTestCase.java
index 29d01ee19..5cd257ba1 100644
--- a/core/src/test/java/google/registry/flows/session/LoginFlowTestCase.java
+++ b/core/src/test/java/google/registry/flows/session/LoginFlowTestCase.java
@@ -18,7 +18,7 @@ import static google.registry.testing.DatastoreHelper.deleteResource;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.EppException.UnimplementedExtensionException;
diff --git a/core/src/test/java/google/registry/flows/session/LogoutFlowTest.java b/core/src/test/java/google/registry/flows/session/LogoutFlowTest.java
index 25db702e2..925a72758 100644
--- a/core/src/test/java/google/registry/flows/session/LogoutFlowTest.java
+++ b/core/src/test/java/google/registry/flows/session/LogoutFlowTest.java
@@ -16,7 +16,7 @@ package google.registry.flows.session;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.flows.EppException;
import google.registry.flows.FlowTestCase;
diff --git a/core/src/test/java/google/registry/groups/DirectoryGroupsConnectionTest.java b/core/src/test/java/google/registry/groups/DirectoryGroupsConnectionTest.java
index 85a11d634..f4aa0a149 100644
--- a/core/src/test/java/google/registry/groups/DirectoryGroupsConnectionTest.java
+++ b/core/src/test/java/google/registry/groups/DirectoryGroupsConnectionTest.java
@@ -19,7 +19,7 @@ import static google.registry.groups.DirectoryGroupsConnection.getDefaultGroupPe
import static javax.servlet.http.HttpServletResponse.SC_CONFLICT;
import static javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
import static javax.servlet.http.HttpServletResponse.SC_NOT_FOUND;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.eq;
diff --git a/core/src/test/java/google/registry/keyring/api/ComparatorKeyringTest.java b/core/src/test/java/google/registry/keyring/api/ComparatorKeyringTest.java
index 22fe6b64c..1c6bda0a8 100644
--- a/core/src/test/java/google/registry/keyring/api/ComparatorKeyringTest.java
+++ b/core/src/test/java/google/registry/keyring/api/ComparatorKeyringTest.java
@@ -17,7 +17,7 @@ package google.registry.keyring.api;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.LogsSubject.assertAboutLogs;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/mapreduce/inputs/ChildEntityInputTest.java b/core/src/test/java/google/registry/mapreduce/inputs/ChildEntityInputTest.java
index d0259bf45..caf93b511 100644
--- a/core/src/test/java/google/registry/mapreduce/inputs/ChildEntityInputTest.java
+++ b/core/src/test/java/google/registry/mapreduce/inputs/ChildEntityInputTest.java
@@ -26,7 +26,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResource;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.tools.mapreduce.InputReader;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/mapreduce/inputs/EppResourceInputsTest.java b/core/src/test/java/google/registry/mapreduce/inputs/EppResourceInputsTest.java
index 6fe8b8ab3..410e812b2 100644
--- a/core/src/test/java/google/registry/mapreduce/inputs/EppResourceInputsTest.java
+++ b/core/src/test/java/google/registry/mapreduce/inputs/EppResourceInputsTest.java
@@ -27,7 +27,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistEppResourceInFirstBucket;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.tools.mapreduce.InputReader;
import com.googlecode.objectify.Key;
diff --git a/core/src/test/java/google/registry/model/OteAccountBuilderTest.java b/core/src/test/java/google/registry/model/OteAccountBuilderTest.java
index 6fd247598..22402335b 100644
--- a/core/src/test/java/google/registry/model/OteAccountBuilderTest.java
+++ b/core/src/test/java/google/registry/model/OteAccountBuilderTest.java
@@ -26,7 +26,7 @@ import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistSimpleResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.model.registrar.Registrar;
diff --git a/core/src/test/java/google/registry/model/billing/BillingEventTest.java b/core/src/test/java/google/registry/model/billing/BillingEventTest.java
index ae3b8da12..941555e52 100644
--- a/core/src/test/java/google/registry/model/billing/BillingEventTest.java
+++ b/core/src/test/java/google/registry/model/billing/BillingEventTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.SqlHelper.saveRegistrar;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/model/common/CursorTest.java b/core/src/test/java/google/registry/model/common/CursorTest.java
index 65d2ae593..0f4a8a6d5 100644
--- a/core/src/test/java/google/registry/model/common/CursorTest.java
+++ b/core/src/test/java/google/registry/model/common/CursorTest.java
@@ -24,7 +24,7 @@ import static google.registry.schema.cursor.CursorDao.loadAndCompare;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.EntityTestCase;
import google.registry.model.domain.DomainBase;
diff --git a/core/src/test/java/google/registry/model/common/TimedTransitionPropertyTest.java b/core/src/test/java/google/registry/model/common/TimedTransitionPropertyTest.java
index 3421c536c..c812003fc 100644
--- a/core/src/test/java/google/registry/model/common/TimedTransitionPropertyTest.java
+++ b/core/src/test/java/google/registry/model/common/TimedTransitionPropertyTest.java
@@ -19,7 +19,7 @@ import static google.registry.model.common.TimedTransitionProperty.forMapify;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.annotations.VisibleForTesting;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/model/contact/ContactResourceTest.java b/core/src/test/java/google/registry/model/contact/ContactResourceTest.java
index 804b4d04e..8979cfa00 100644
--- a/core/src/test/java/google/registry/model/contact/ContactResourceTest.java
+++ b/core/src/test/java/google/registry/model/contact/ContactResourceTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.SqlHelper.assertThrowForeignKeyViolation;
import static google.registry.testing.SqlHelper.saveRegistrar;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/model/domain/DomainBaseTest.java b/core/src/test/java/google/registry/model/domain/DomainBaseTest.java
index 8c03174a6..7b7f9c68f 100644
--- a/core/src/test/java/google/registry/model/domain/DomainBaseTest.java
+++ b/core/src/test/java/google/registry/model/domain/DomainBaseTest.java
@@ -28,7 +28,7 @@ import static google.registry.testing.DomainBaseSubject.assertAboutDomains;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/model/domain/GracePeriodTest.java b/core/src/test/java/google/registry/model/domain/GracePeriodTest.java
index 5d765ea8c..1fd9f6d0a 100644
--- a/core/src/test/java/google/registry/model/domain/GracePeriodTest.java
+++ b/core/src/test/java/google/registry/model/domain/GracePeriodTest.java
@@ -16,7 +16,7 @@ package google.registry.model.domain;
import static com.google.common.truth.Truth.assertThat;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.googlecode.objectify.Key;
import google.registry.model.billing.BillingEvent;
diff --git a/core/src/test/java/google/registry/model/domain/token/AllocationTokenTest.java b/core/src/test/java/google/registry/model/domain/token/AllocationTokenTest.java
index 69a9b03b7..d09a7e451 100644
--- a/core/src/test/java/google/registry/model/domain/token/AllocationTokenTest.java
+++ b/core/src/test/java/google/registry/model/domain/token/AllocationTokenTest.java
@@ -27,7 +27,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/model/eppcommon/EppXmlTransformerTest.java b/core/src/test/java/google/registry/model/eppcommon/EppXmlTransformerTest.java
index 558d46ecc..5e10fb7d5 100644
--- a/core/src/test/java/google/registry/model/eppcommon/EppXmlTransformerTest.java
+++ b/core/src/test/java/google/registry/model/eppcommon/EppXmlTransformerTest.java
@@ -17,7 +17,7 @@ package google.registry.model.eppcommon;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.model.eppcommon.EppXmlTransformer.unmarshal;
import static google.registry.testing.TestDataHelper.loadBytes;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.eppinput.EppInput;
import google.registry.model.eppoutput.EppOutput;
diff --git a/core/src/test/java/google/registry/model/eppinput/EppInputTest.java b/core/src/test/java/google/registry/model/eppinput/EppInputTest.java
index a7c45e6b2..bfd4ba974 100644
--- a/core/src/test/java/google/registry/model/eppinput/EppInputTest.java
+++ b/core/src/test/java/google/registry/model/eppinput/EppInputTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
import static google.registry.model.eppcommon.EppXmlTransformer.unmarshal;
import static google.registry.testing.TestDataHelper.loadBytes;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.contact.ContactResourceTest;
import google.registry.model.domain.DomainBaseTest;
diff --git a/core/src/test/java/google/registry/model/host/HostResourceTest.java b/core/src/test/java/google/registry/model/host/HostResourceTest.java
index 4b1beb341..78e49cfb9 100644
--- a/core/src/test/java/google/registry/model/host/HostResourceTest.java
+++ b/core/src/test/java/google/registry/model/host/HostResourceTest.java
@@ -22,7 +22,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.HostResourceSubject.assertAboutHosts;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.net.InetAddresses;
diff --git a/core/src/test/java/google/registry/model/ofy/CommitLogBucketTest.java b/core/src/test/java/google/registry/model/ofy/CommitLogBucketTest.java
index 770734227..3dbab313e 100644
--- a/core/src/test/java/google/registry/model/ofy/CommitLogBucketTest.java
+++ b/core/src/test/java/google/registry/model/ofy/CommitLogBucketTest.java
@@ -20,7 +20,7 @@ import static google.registry.model.ofy.CommitLogBucket.loadAllBuckets;
import static google.registry.model.ofy.CommitLogBucket.loadBucket;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.END_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Suppliers;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/model/ofy/CommitLogCheckpointTest.java b/core/src/test/java/google/registry/model/ofy/CommitLogCheckpointTest.java
index dddcfb805..26fc40f86 100644
--- a/core/src/test/java/google/registry/model/ofy/CommitLogCheckpointTest.java
+++ b/core/src/test/java/google/registry/model/ofy/CommitLogCheckpointTest.java
@@ -17,7 +17,7 @@ package google.registry.model.ofy;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/model/ofy/OfyCommitLogTest.java b/core/src/test/java/google/registry/model/ofy/OfyCommitLogTest.java
index 0d1549339..4baead268 100644
--- a/core/src/test/java/google/registry/model/ofy/OfyCommitLogTest.java
+++ b/core/src/test/java/google/registry/model/ofy/OfyCommitLogTest.java
@@ -20,7 +20,7 @@ import static google.registry.model.common.EntityGroupRoot.getCrossTldKey;
import static google.registry.model.ofy.CommitLogBucket.getBucketKey;
import static google.registry.model.ofy.ObjectifyService.ofy;
import static google.registry.persistence.transaction.TransactionManagerFactory.tm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.googlecode.objectify.Key;
diff --git a/core/src/test/java/google/registry/model/ofy/OfyFilterTest.java b/core/src/test/java/google/registry/model/ofy/OfyFilterTest.java
index 212d25a61..195530302 100644
--- a/core/src/test/java/google/registry/model/ofy/OfyFilterTest.java
+++ b/core/src/test/java/google/registry/model/ofy/OfyFilterTest.java
@@ -17,7 +17,7 @@ package google.registry.model.ofy;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.model.ofy.ObjectifyService.initOfy;
import static google.registry.testing.DatastoreHelper.newContactResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.tools.development.testing.LocalDatastoreServiceTestConfig;
import com.google.appengine.tools.development.testing.LocalServiceTestHelper;
diff --git a/core/src/test/java/google/registry/model/ofy/OfyTest.java b/core/src/test/java/google/registry/model/ofy/OfyTest.java
index c52e0dc3a..9cf8bd430 100644
--- a/core/src/test/java/google/registry/model/ofy/OfyTest.java
+++ b/core/src/test/java/google/registry/model/ofy/OfyTest.java
@@ -28,8 +28,8 @@ import static google.registry.util.DateTimeUtils.END_OF_TIME;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static java.nio.charset.StandardCharsets.UTF_8;
import static java.util.concurrent.TimeUnit.MILLISECONDS;
-import static org.junit.Assert.assertThrows;
-import static org.junit.Assert.fail;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assertions.fail;
import com.google.appengine.api.datastore.DatastoreFailureException;
import com.google.appengine.api.datastore.DatastoreTimeoutException;
diff --git a/core/src/test/java/google/registry/model/poll/PollMessageExternalKeyConverterTest.java b/core/src/test/java/google/registry/model/poll/PollMessageExternalKeyConverterTest.java
index eea803237..2b0397303 100644
--- a/core/src/test/java/google/registry/model/poll/PollMessageExternalKeyConverterTest.java
+++ b/core/src/test/java/google/registry/model/poll/PollMessageExternalKeyConverterTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistResource;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.googlecode.objectify.Key;
import google.registry.model.domain.Period;
diff --git a/core/src/test/java/google/registry/model/rde/RdeNamingUtilsTest.java b/core/src/test/java/google/registry/model/rde/RdeNamingUtilsTest.java
index b5c8639ee..cc2f2f2a9 100644
--- a/core/src/test/java/google/registry/model/rde/RdeNamingUtilsTest.java
+++ b/core/src/test/java/google/registry/model/rde/RdeNamingUtilsTest.java
@@ -19,7 +19,7 @@ import static google.registry.model.rde.RdeMode.FULL;
import static google.registry.model.rde.RdeMode.THIN;
import static google.registry.model.rde.RdeNamingUtils.makePartialName;
import static google.registry.model.rde.RdeNamingUtils.makeRydeFilename;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.joda.time.DateTime;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/model/rde/RdeRevisionTest.java b/core/src/test/java/google/registry/model/rde/RdeRevisionTest.java
index 6a71c6a71..3ae9a1193 100644
--- a/core/src/test/java/google/registry/model/rde/RdeRevisionTest.java
+++ b/core/src/test/java/google/registry/model/rde/RdeRevisionTest.java
@@ -20,7 +20,7 @@ import static google.registry.model.rde.RdeMode.FULL;
import static google.registry.model.rde.RdeRevision.getNextRevision;
import static google.registry.model.rde.RdeRevision.saveRevision;
import static google.registry.persistence.transaction.TransactionManagerFactory.tm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.VerifyException;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/model/registrar/RegistrarTest.java b/core/src/test/java/google/registry/model/registrar/RegistrarTest.java
index a9618b145..94c1fb2b6 100644
--- a/core/src/test/java/google/registry/model/registrar/RegistrarTest.java
+++ b/core/src/test/java/google/registry/model/registrar/RegistrarTest.java
@@ -29,7 +29,7 @@ import static google.registry.testing.DatastoreHelper.newRegistry;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResources;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/model/registry/RegistriesTest.java b/core/src/test/java/google/registry/model/registry/RegistriesTest.java
index 9440eb871..42f86d724 100644
--- a/core/src/test/java/google/registry/model/registry/RegistriesTest.java
+++ b/core/src/test/java/google/registry/model/registry/RegistriesTest.java
@@ -19,7 +19,7 @@ import static com.google.common.truth.Truth8.assertThat;
import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.newRegistry;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.net.InternetDomainName;
import google.registry.model.registry.Registry.TldType;
diff --git a/core/src/test/java/google/registry/model/registry/RegistryLockDaoTest.java b/core/src/test/java/google/registry/model/registry/RegistryLockDaoTest.java
index 1564f1227..01d55473f 100644
--- a/core/src/test/java/google/registry/model/registry/RegistryLockDaoTest.java
+++ b/core/src/test/java/google/registry/model/registry/RegistryLockDaoTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.SqlHelper.getRegistryLockByRevisionId;
import static google.registry.testing.SqlHelper.getRegistryLockByVerificationCode;
import static google.registry.testing.SqlHelper.getRegistryLocksByRegistrarId;
import static google.registry.testing.SqlHelper.saveRegistryLock;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.EntityTestCase;
import google.registry.schema.domain.RegistryLock;
diff --git a/core/src/test/java/google/registry/model/registry/RegistryTest.java b/core/src/test/java/google/registry/model/registry/RegistryTest.java
index ced7963ce..a21e5730a 100644
--- a/core/src/test/java/google/registry/model/registry/RegistryTest.java
+++ b/core/src/test/java/google/registry/model/registry/RegistryTest.java
@@ -32,7 +32,7 @@ import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static java.math.BigDecimal.ROUND_UNNECESSARY;
import static org.joda.money.CurrencyUnit.EUR;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/model/registry/label/PremiumListTest.java b/core/src/test/java/google/registry/model/registry/label/PremiumListTest.java
index e8d30d50f..39d6f6d68 100644
--- a/core/src/test/java/google/registry/model/registry/label/PremiumListTest.java
+++ b/core/src/test/java/google/registry/model/registry/label/PremiumListTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistReservedList;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.model.registry.Registry;
diff --git a/core/src/test/java/google/registry/model/registry/label/PremiumListUtilsTest.java b/core/src/test/java/google/registry/model/registry/label/PremiumListUtilsTest.java
index 2d60411ed..92da0da18 100644
--- a/core/src/test/java/google/registry/model/registry/label/PremiumListUtilsTest.java
+++ b/core/src/test/java/google/registry/model/registry/label/PremiumListUtilsTest.java
@@ -36,7 +36,7 @@ import static google.registry.testing.DatastoreHelper.loadPremiumListEntries;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.Duration.standardDays;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/model/registry/label/ReservedListTest.java b/core/src/test/java/google/registry/model/registry/label/ReservedListTest.java
index 63e583e75..f0cc15395 100644
--- a/core/src/test/java/google/registry/model/registry/label/ReservedListTest.java
+++ b/core/src/test/java/google/registry/model/registry/label/ReservedListTest.java
@@ -28,7 +28,7 @@ import static google.registry.model.registry.label.ReservedList.getReservationTy
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistReservedList;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/model/reporting/Spec11ThreatMatchTest.java b/core/src/test/java/google/registry/model/reporting/Spec11ThreatMatchTest.java
index e9615b21d..62031e256 100644
--- a/core/src/test/java/google/registry/model/reporting/Spec11ThreatMatchTest.java
+++ b/core/src/test/java/google/registry/model/reporting/Spec11ThreatMatchTest.java
@@ -21,7 +21,7 @@ import static google.registry.persistence.transaction.TransactionManagerFactory.
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.SqlHelper.assertThrowForeignKeyViolation;
import static google.registry.testing.SqlHelper.saveRegistrar;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import google.registry.model.EntityTestCase;
diff --git a/core/src/test/java/google/registry/model/server/KmsSecretRevisionTest.java b/core/src/test/java/google/registry/model/server/KmsSecretRevisionTest.java
index dadc74fdf..1d0b6b9aa 100644
--- a/core/src/test/java/google/registry/model/server/KmsSecretRevisionTest.java
+++ b/core/src/test/java/google/registry/model/server/KmsSecretRevisionTest.java
@@ -17,7 +17,7 @@ package google.registry.model.server;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.model.ofy.ObjectifyService.ofy;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Strings;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/model/server/LockTest.java b/core/src/test/java/google/registry/model/server/LockTest.java
index 6524e4934..d72431310 100644
--- a/core/src/test/java/google/registry/model/server/LockTest.java
+++ b/core/src/test/java/google/registry/model/server/LockTest.java
@@ -20,7 +20,7 @@ import static google.registry.model.server.Lock.LockState.FREE;
import static google.registry.model.server.Lock.LockState.IN_USE;
import static google.registry.model.server.Lock.LockState.OWNER_DIED;
import static google.registry.model.server.Lock.LockState.TIMED_OUT;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/core/src/test/java/google/registry/model/smd/SignedMarkRevocationListTest.java b/core/src/test/java/google/registry/model/smd/SignedMarkRevocationListTest.java
index ddcd95954..b9b4a0b35 100644
--- a/core/src/test/java/google/registry/model/smd/SignedMarkRevocationListTest.java
+++ b/core/src/test/java/google/registry/model/smd/SignedMarkRevocationListTest.java
@@ -20,7 +20,7 @@ import static google.registry.model.smd.SignedMarkRevocationList.SHARD_SIZE;
import static google.registry.persistence.transaction.TransactionManagerFactory.tm;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.Duration.standardDays;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/model/tmch/ClaimsListShardTest.java b/core/src/test/java/google/registry/model/tmch/ClaimsListShardTest.java
index 547f2feeb..cabdd0f88 100644
--- a/core/src/test/java/google/registry/model/tmch/ClaimsListShardTest.java
+++ b/core/src/test/java/google/registry/model/tmch/ClaimsListShardTest.java
@@ -20,7 +20,7 @@ import static google.registry.model.ofy.ObjectifyService.ofy;
import static google.registry.persistence.transaction.TransactionManagerFactory.tm;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.googlecode.objectify.Key;
diff --git a/core/src/test/java/google/registry/model/translators/VKeyTranslatorFactoryTest.java b/core/src/test/java/google/registry/model/translators/VKeyTranslatorFactoryTest.java
index 0399d1080..084f0f776 100644
--- a/core/src/test/java/google/registry/model/translators/VKeyTranslatorFactoryTest.java
+++ b/core/src/test/java/google/registry/model/translators/VKeyTranslatorFactoryTest.java
@@ -17,7 +17,7 @@ package google.registry.model.translators;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistActiveContact;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.googlecode.objectify.Key;
import google.registry.model.domain.DomainBase;
diff --git a/core/src/test/java/google/registry/persistence/converter/CurrencyUnitConverterTest.java b/core/src/test/java/google/registry/persistence/converter/CurrencyUnitConverterTest.java
index e09d60100..7cb235c39 100644
--- a/core/src/test/java/google/registry/persistence/converter/CurrencyUnitConverterTest.java
+++ b/core/src/test/java/google/registry/persistence/converter/CurrencyUnitConverterTest.java
@@ -16,7 +16,7 @@ package google.registry.persistence.converter;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.ImmutableObject;
import google.registry.persistence.transaction.JpaTestRules;
diff --git a/core/src/test/java/google/registry/persistence/converter/StringListConverterTest.java b/core/src/test/java/google/registry/persistence/converter/StringListConverterTest.java
index c61ecafc4..a64cb37cb 100644
--- a/core/src/test/java/google/registry/persistence/converter/StringListConverterTest.java
+++ b/core/src/test/java/google/registry/persistence/converter/StringListConverterTest.java
@@ -16,7 +16,7 @@ package google.registry.persistence.converter;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.model.ImmutableObject;
diff --git a/core/src/test/java/google/registry/persistence/converter/StringMapConverterBaseTest.java b/core/src/test/java/google/registry/persistence/converter/StringMapConverterBaseTest.java
index 8c323a66d..78580e5c7 100644
--- a/core/src/test/java/google/registry/persistence/converter/StringMapConverterBaseTest.java
+++ b/core/src/test/java/google/registry/persistence/converter/StringMapConverterBaseTest.java
@@ -16,7 +16,7 @@ package google.registry.persistence.converter;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.Maps;
diff --git a/core/src/test/java/google/registry/persistence/converter/TimedTransitionPropertyConverterBaseTest.java b/core/src/test/java/google/registry/persistence/converter/TimedTransitionPropertyConverterBaseTest.java
index 82fd2d94d..487bad7ed 100644
--- a/core/src/test/java/google/registry/persistence/converter/TimedTransitionPropertyConverterBaseTest.java
+++ b/core/src/test/java/google/registry/persistence/converter/TimedTransitionPropertyConverterBaseTest.java
@@ -17,7 +17,7 @@ package google.registry.persistence.converter;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSortedMap;
import com.google.common.collect.Maps;
diff --git a/core/src/test/java/google/registry/persistence/transaction/DummyJpaTransactionManagerTest.java b/core/src/test/java/google/registry/persistence/transaction/DummyJpaTransactionManagerTest.java
index 658100b7f..8c9cd6d22 100644
--- a/core/src/test/java/google/registry/persistence/transaction/DummyJpaTransactionManagerTest.java
+++ b/core/src/test/java/google/registry/persistence/transaction/DummyJpaTransactionManagerTest.java
@@ -15,7 +15,7 @@
package google.registry.persistence.transaction;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.testing.AppEngineExtension;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerImplTest.java b/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerImplTest.java
index 91f604252..586867709 100644
--- a/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerImplTest.java
+++ b/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerImplTest.java
@@ -17,7 +17,7 @@ package google.registry.persistence.transaction;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
import static google.registry.testing.TestDataHelper.fileClassPath;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.model.ImmutableObject;
diff --git a/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerRuleTest.java b/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerRuleTest.java
index ccf2d6b1f..cac2e3fd5 100644
--- a/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerRuleTest.java
+++ b/core/src/test/java/google/registry/persistence/transaction/JpaTransactionManagerRuleTest.java
@@ -16,7 +16,7 @@ package google.registry.persistence.transaction;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.ImmutableObject;
import google.registry.persistence.transaction.JpaTestRules.JpaUnitTestExtension;
diff --git a/core/src/test/java/google/registry/persistence/transaction/TestCaseWatcher.java b/core/src/test/java/google/registry/persistence/transaction/TestCaseWatcher.java
deleted file mode 100644
index dbed29539..000000000
--- a/core/src/test/java/google/registry/persistence/transaction/TestCaseWatcher.java
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright 2018 The Nomulus Authors. All Rights Reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package google.registry.persistence.transaction;
-
-import static com.google.common.base.Preconditions.checkState;
-
-import org.junit.rules.TestWatcher;
-import org.junit.runner.Description;
-
-/** Keeps track of the current class and method under test. */
-public class TestCaseWatcher extends TestWatcher {
-
- private Description currentDescription;
-
- @Override
- protected void starting(Description description) {
- this.currentDescription = description;
- }
-
- private void validateState() {
- checkState(
- currentDescription != null,
- "Tests have not started yet. Make sure invocation is from inner rule or test code.");
- }
-
- public String getTestClass() {
- validateState();
- return currentDescription.getClassName();
- }
-
- public String getTestMethod() {
- validateState();
- return currentDescription.getMethodName();
- }
-}
diff --git a/core/src/test/java/google/registry/persistence/transaction/TransactionManagerTest.java b/core/src/test/java/google/registry/persistence/transaction/TransactionManagerTest.java
index f1df41cf5..9290e4ce7 100644
--- a/core/src/test/java/google/registry/persistence/transaction/TransactionManagerTest.java
+++ b/core/src/test/java/google/registry/persistence/transaction/TransactionManagerTest.java
@@ -18,7 +18,7 @@ import static com.google.common.collect.ImmutableList.toImmutableList;
import static com.google.common.collect.ImmutableSet.toImmutableSet;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.tm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.Maps;
diff --git a/core/src/test/java/google/registry/persistence/transaction/TransactionTest.java b/core/src/test/java/google/registry/persistence/transaction/TransactionTest.java
index c3a6e9e3b..bcf9aa7b6 100644
--- a/core/src/test/java/google/registry/persistence/transaction/TransactionTest.java
+++ b/core/src/test/java/google/registry/persistence/transaction/TransactionTest.java
@@ -17,7 +17,7 @@ package google.registry.persistence.transaction;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
import static google.registry.persistence.transaction.TransactionManagerFactory.ofyTm;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.googlecode.objectify.Key;
import com.googlecode.objectify.annotation.Entity;
diff --git a/core/src/test/java/google/registry/pricing/PricingEngineProxyTest.java b/core/src/test/java/google/registry/pricing/PricingEngineProxyTest.java
index 89110ef2e..7aac5e83d 100644
--- a/core/src/test/java/google/registry/pricing/PricingEngineProxyTest.java
+++ b/core/src/test/java/google/registry/pricing/PricingEngineProxyTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSortedMap;
import google.registry.model.registry.Registry;
diff --git a/core/src/test/java/google/registry/rdap/AbstractJsonableObjectTest.java b/core/src/test/java/google/registry/rdap/AbstractJsonableObjectTest.java
index 552536825..ac74e1063 100644
--- a/core/src/test/java/google/registry/rdap/AbstractJsonableObjectTest.java
+++ b/core/src/test/java/google/registry/rdap/AbstractJsonableObjectTest.java
@@ -15,7 +15,7 @@
package google.registry.rdap;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Joiner;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/rdap/RdapSearchPatternTest.java b/core/src/test/java/google/registry/rdap/RdapSearchPatternTest.java
index 00b313bd7..c88b164ae 100644
--- a/core/src/test/java/google/registry/rdap/RdapSearchPatternTest.java
+++ b/core/src/test/java/google/registry/rdap/RdapSearchPatternTest.java
@@ -15,7 +15,7 @@
package google.registry.rdap;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.request.HttpException.UnprocessableEntityException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/rdap/UpdateRegistrarRdapBaseUrlsActionTest.java b/core/src/test/java/google/registry/rdap/UpdateRegistrarRdapBaseUrlsActionTest.java
index d24da7c07..cb1fccda2 100644
--- a/core/src/test/java/google/registry/rdap/UpdateRegistrarRdapBaseUrlsActionTest.java
+++ b/core/src/test/java/google/registry/rdap/UpdateRegistrarRdapBaseUrlsActionTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.deleteTld;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.api.client.http.LowLevelHttpRequest;
import com.google.api.client.testing.http.MockHttpTransport;
diff --git a/core/src/test/java/google/registry/rde/BrdaCopyActionTest.java b/core/src/test/java/google/registry/rde/BrdaCopyActionTest.java
index 7e3a15fb9..229b49827 100644
--- a/core/src/test/java/google/registry/rde/BrdaCopyActionTest.java
+++ b/core/src/test/java/google/registry/rde/BrdaCopyActionTest.java
@@ -19,7 +19,7 @@ import static com.google.common.truth.Truth.assertWithMessage;
import static google.registry.testing.GcsTestingUtils.readGcsFile;
import static google.registry.testing.SystemInfo.hasCommand;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assume.assumeTrue;
+import static org.junit.jupiter.api.Assumptions.assumeTrue;
import com.google.appengine.tools.cloudstorage.GcsFilename;
import com.google.appengine.tools.cloudstorage.GcsService;
diff --git a/core/src/test/java/google/registry/rde/EscrowTaskRunnerTest.java b/core/src/test/java/google/registry/rde/EscrowTaskRunnerTest.java
index 82a826ecf..d92d514d4 100644
--- a/core/src/test/java/google/registry/rde/EscrowTaskRunnerTest.java
+++ b/core/src/test/java/google/registry/rde/EscrowTaskRunnerTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.Duration.standardDays;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/rde/GhostrydeGpgIntegrationTest.java b/core/src/test/java/google/registry/rde/GhostrydeGpgIntegrationTest.java
index 3b38fe563..d6541896d 100644
--- a/core/src/test/java/google/registry/rde/GhostrydeGpgIntegrationTest.java
+++ b/core/src/test/java/google/registry/rde/GhostrydeGpgIntegrationTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth.assertWithMessage;
import static google.registry.testing.SystemInfo.hasCommand;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assume.assumeTrue;
+import static org.junit.jupiter.api.Assumptions.assumeTrue;
import com.google.common.base.Strings;
import com.google.common.collect.ImmutableList;
@@ -44,10 +44,10 @@ import org.junit.jupiter.params.provider.MethodSource;
class GhostrydeGpgIntegrationTest {
@RegisterExtension
- public final BouncyCastleProviderExtension bouncy = new BouncyCastleProviderExtension();
+ final BouncyCastleProviderExtension bouncy = new BouncyCastleProviderExtension();
@RegisterExtension
- public final GpgSystemCommandExtension gpg =
+ final GpgSystemCommandExtension gpg =
new GpgSystemCommandExtension(
RdeTestData.loadBytes("pgp-public-keyring.asc"),
RdeTestData.loadBytes("pgp-private-keyring-registry.asc"));
diff --git a/core/src/test/java/google/registry/rde/GhostrydeTest.java b/core/src/test/java/google/registry/rde/GhostrydeTest.java
index 88a696c59..42d6cfcd0 100644
--- a/core/src/test/java/google/registry/rde/GhostrydeTest.java
+++ b/core/src/test/java/google/registry/rde/GhostrydeTest.java
@@ -17,14 +17,10 @@ package google.registry.rde;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.keyring.api.PgpHelper.KeyRequirement.ENCRYPT;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.hamcrest.Matchers.greaterThan;
-import static org.hamcrest.Matchers.is;
-import static org.hamcrest.Matchers.lessThan;
-import static org.junit.Assert.assertThrows;
-import static org.junit.Assume.assumeThat;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assumptions.assumeTrue;
import com.google.common.base.Strings;
-import com.google.common.collect.ImmutableList;
import com.google.common.io.ByteStreams;
import google.registry.keyring.api.Keyring;
import google.registry.testing.BouncyCastleProviderExtension;
@@ -53,17 +49,15 @@ public class GhostrydeTest {
@RegisterExtension
public final BouncyCastleProviderExtension bouncy = new BouncyCastleProviderExtension();
- private static final ImmutableList CONTENTS =
- ImmutableList.of(
- "hi",
- "(◕‿◕)",
- Strings.repeat("Fanatics have their dreams, wherewith they weave\n", 1000),
- "\0yolo",
- "");
-
@SuppressWarnings("unused")
static Stream provideTestCombinations() {
- return CONTENTS.stream().map(Arguments::of);
+ return Stream.of(
+ "hi",
+ "(◕‿◕)",
+ Strings.repeat("Fanatics have their dreams, wherewith they weave\n", 1000),
+ "\0yolo",
+ "")
+ .map(Arguments::of);
}
@ParameterizedTest
@@ -124,7 +118,7 @@ public class GhostrydeTest {
@ParameterizedTest
@MethodSource("provideTestCombinations")
void testFailure_tampering(String content) throws Exception {
- assumeThat(content.length(), is(greaterThan(100)));
+ assumeTrue(content.length() > 100);
Keyring keyring = new FakeKeyringModule().get();
PGPPublicKey publicKey = keyring.getRdeStagingEncryptionKey();
@@ -154,7 +148,7 @@ public class GhostrydeTest {
@ParameterizedTest
@MethodSource("provideTestCombinations")
void testFailure_corruption(String content) throws Exception {
- assumeThat(content.length(), is(lessThan(100)));
+ assumeTrue(content.length() < 100);
Keyring keyring = new FakeKeyringModule().get();
PGPPublicKey publicKey = keyring.getRdeStagingEncryptionKey();
@@ -257,10 +251,11 @@ public class GhostrydeTest {
// Make the last byte of the private key off by one. muahahaha
byte[] keyData = rsa.getPrivateKey().getPrivateKeyDataPacket().getEncoded();
keyData[keyData.length - 1]++;
- PGPPrivateKey privateKey = new PGPPrivateKey(
- rsa.getKeyID(),
- rsa.getPrivateKey().getPublicKeyPacket(),
- rsa.getPrivateKey().getPrivateKeyDataPacket());
+ PGPPrivateKey privateKey =
+ new PGPPrivateKey(
+ rsa.getKeyID(),
+ rsa.getPrivateKey().getPublicKeyPacket(),
+ rsa.getPrivateKey().getPrivateKeyDataPacket());
ByteArrayOutputStream bsOut = new ByteArrayOutputStream();
try (OutputStream encoder = Ghostryde.encoder(bsOut, publicKey)) {
diff --git a/core/src/test/java/google/registry/rde/HostResourceToXjcConverterTest.java b/core/src/test/java/google/registry/rde/HostResourceToXjcConverterTest.java
index 7fcc6dbc2..176a2b697 100644
--- a/core/src/test/java/google/registry/rde/HostResourceToXjcConverterTest.java
+++ b/core/src/test/java/google/registry/rde/HostResourceToXjcConverterTest.java
@@ -19,7 +19,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.xjc.XjcXmlTransformer.marshalStrict;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.net.InetAddresses;
diff --git a/core/src/test/java/google/registry/rde/RdeReportActionTest.java b/core/src/test/java/google/registry/rde/RdeReportActionTest.java
index 748153517..54d9d17cf 100644
--- a/core/src/test/java/google/registry/rde/RdeReportActionTest.java
+++ b/core/src/test/java/google/registry/rde/RdeReportActionTest.java
@@ -27,7 +27,7 @@ import static javax.servlet.http.HttpServletResponse.SC_BAD_REQUEST;
import static javax.servlet.http.HttpServletResponse.SC_OK;
import static org.joda.time.Duration.standardDays;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/rde/RdeStagingActionTest.java b/core/src/test/java/google/registry/rde/RdeStagingActionTest.java
index 1d8173fd4..f8467982b 100644
--- a/core/src/test/java/google/registry/rde/RdeStagingActionTest.java
+++ b/core/src/test/java/google/registry/rde/RdeStagingActionTest.java
@@ -33,7 +33,7 @@ import static google.registry.testing.TestDataHelper.loadFile;
import static google.registry.tldconfig.idn.IdnTableEnum.EXTENDED_LATIN;
import static java.nio.charset.StandardCharsets.UTF_8;
import static java.util.Arrays.asList;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.tools.cloudstorage.GcsFilename;
import com.google.appengine.tools.cloudstorage.GcsService;
diff --git a/core/src/test/java/google/registry/rde/RdeUploadActionTest.java b/core/src/test/java/google/registry/rde/RdeUploadActionTest.java
index 072987433..eb7df097d 100644
--- a/core/src/test/java/google/registry/rde/RdeUploadActionTest.java
+++ b/core/src/test/java/google/registry/rde/RdeUploadActionTest.java
@@ -33,8 +33,8 @@ import static java.nio.charset.StandardCharsets.UTF_8;
import static org.joda.time.Duration.standardDays;
import static org.joda.time.Duration.standardHours;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
-import static org.junit.Assume.assumeTrue;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assumptions.assumeTrue;
import static org.mockito.ArgumentMatchers.anyInt;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.Mockito.mock;
@@ -72,7 +72,7 @@ import google.registry.testing.FakeSleeper;
import google.registry.testing.GpgSystemCommandExtension;
import google.registry.testing.Lazies;
import google.registry.testing.TaskQueueHelper.TaskMatcher;
-import google.registry.testing.sftp.SftpServerRule;
+import google.registry.testing.sftp.SftpServerExtension;
import google.registry.util.Retrier;
import google.registry.util.TaskQueueUtils;
import java.io.File;
@@ -110,7 +110,7 @@ public class RdeUploadActionTest {
private static final GcsFilename REPORT_R1_FILE =
new GcsFilename("bucket", "tld_2010-10-17_full_S1_R1-report.xml.ghostryde");
- @RegisterExtension final SftpServerRule sftpd = new SftpServerRule();
+ @RegisterExtension final SftpServerExtension sftpd = new SftpServerExtension();
@SuppressWarnings("WeakerAccess")
@TempDir
diff --git a/core/src/test/java/google/registry/rde/RydeEncryptionTest.java b/core/src/test/java/google/registry/rde/RydeEncryptionTest.java
index 2c3905542..3800e1bdb 100644
--- a/core/src/test/java/google/registry/rde/RydeEncryptionTest.java
+++ b/core/src/test/java/google/registry/rde/RydeEncryptionTest.java
@@ -17,7 +17,7 @@ package google.registry.rde;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.keyring.api.PgpHelper.KeyRequirement.ENCRYPT;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.io.ByteStreams;
diff --git a/core/src/test/java/google/registry/rde/RydeGpgIntegrationTest.java b/core/src/test/java/google/registry/rde/RydeGpgIntegrationTest.java
index f61c06c63..0d05d653b 100644
--- a/core/src/test/java/google/registry/rde/RydeGpgIntegrationTest.java
+++ b/core/src/test/java/google/registry/rde/RydeGpgIntegrationTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth.assertWithMessage;
import static google.registry.testing.SystemInfo.hasCommand;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assume.assumeTrue;
+import static org.junit.jupiter.api.Assumptions.assumeTrue;
import com.google.common.base.Strings;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/reporting/ReportingModuleTest.java b/core/src/test/java/google/registry/reporting/ReportingModuleTest.java
index d1050f923..6bd473372 100644
--- a/core/src/test/java/google/registry/reporting/ReportingModuleTest.java
+++ b/core/src/test/java/google/registry/reporting/ReportingModuleTest.java
@@ -15,7 +15,7 @@
package google.registry.reporting;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/reporting/billing/BillingEmailUtilsTest.java b/core/src/test/java/google/registry/reporting/billing/BillingEmailUtilsTest.java
index 25f97699a..b4089250c 100644
--- a/core/src/test/java/google/registry/reporting/billing/BillingEmailUtilsTest.java
+++ b/core/src/test/java/google/registry/reporting/billing/BillingEmailUtilsTest.java
@@ -16,7 +16,7 @@ package google.registry.reporting.billing;
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
diff --git a/core/src/test/java/google/registry/reporting/icann/IcannHttpReporterTest.java b/core/src/test/java/google/registry/reporting/icann/IcannHttpReporterTest.java
index 2a852e18e..b798fe2c7 100644
--- a/core/src/test/java/google/registry/reporting/icann/IcannHttpReporterTest.java
+++ b/core/src/test/java/google/registry/reporting/icann/IcannHttpReporterTest.java
@@ -19,7 +19,7 @@ import static com.google.common.net.MediaType.PLAIN_TEXT_UTF_8;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.api.client.http.LowLevelHttpRequest;
import com.google.api.client.http.LowLevelHttpResponse;
diff --git a/core/src/test/java/google/registry/reporting/icann/IcannReportingStagingActionTest.java b/core/src/test/java/google/registry/reporting/icann/IcannReportingStagingActionTest.java
index 1ba45a333..16c9f615a 100644
--- a/core/src/test/java/google/registry/reporting/icann/IcannReportingStagingActionTest.java
+++ b/core/src/test/java/google/registry/reporting/icann/IcannReportingStagingActionTest.java
@@ -17,7 +17,7 @@ package google.registry.reporting.icann;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.TaskQueueHelper.assertNoTasksEnqueued;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/reporting/icann/IcannReportingUploadActionTest.java b/core/src/test/java/google/registry/reporting/icann/IcannReportingUploadActionTest.java
index 2e2766d6b..330ef8f80 100644
--- a/core/src/test/java/google/registry/reporting/icann/IcannReportingUploadActionTest.java
+++ b/core/src/test/java/google/registry/reporting/icann/IcannReportingUploadActionTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.GcsTestingUtils.writeGcsFile;
import static google.registry.testing.LogsSubject.assertAboutLogs;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/reporting/spec11/Spec11EmailUtilsTest.java b/core/src/test/java/google/registry/reporting/spec11/Spec11EmailUtilsTest.java
index ec0fdd1ec..5bfb9896d 100644
--- a/core/src/test/java/google/registry/reporting/spec11/Spec11EmailUtilsTest.java
+++ b/core/src/test/java/google/registry/reporting/spec11/Spec11EmailUtilsTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
diff --git a/core/src/test/java/google/registry/request/RequestModuleTest.java b/core/src/test/java/google/registry/request/RequestModuleTest.java
index 083c317e4..483d478ff 100644
--- a/core/src/test/java/google/registry/request/RequestModuleTest.java
+++ b/core/src/test/java/google/registry/request/RequestModuleTest.java
@@ -16,7 +16,7 @@ package google.registry.request;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.request.RequestModule.provideJsonPayload;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.net.MediaType;
import google.registry.request.HttpException.BadRequestException;
diff --git a/core/src/test/java/google/registry/request/RequestParametersTest.java b/core/src/test/java/google/registry/request/RequestParametersTest.java
index 0e1f976f8..6d220079c 100644
--- a/core/src/test/java/google/registry/request/RequestParametersTest.java
+++ b/core/src/test/java/google/registry/request/RequestParametersTest.java
@@ -25,7 +25,7 @@ import static google.registry.request.RequestParameters.extractRequiredDatetimeP
import static google.registry.request.RequestParameters.extractRequiredParameter;
import static google.registry.request.RequestParameters.extractSetOfEnumParameters;
import static google.registry.request.RequestParameters.extractSetOfParameters;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/request/RouterTest.java b/core/src/test/java/google/registry/request/RouterTest.java
index fc8aa6ade..be9b5cf98 100644
--- a/core/src/test/java/google/registry/request/RouterTest.java
+++ b/core/src/test/java/google/registry/request/RouterTest.java
@@ -17,7 +17,7 @@ package google.registry.request;
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
import static google.registry.request.auth.Auth.AUTH_INTERNAL_OR_ADMIN;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import java.util.Optional;
import java.util.concurrent.Callable;
diff --git a/core/src/test/java/google/registry/request/auth/AuthenticatedRegistrarAccessorTest.java b/core/src/test/java/google/registry/request/auth/AuthenticatedRegistrarAccessorTest.java
index b5463787e..05c5eac89 100644
--- a/core/src/test/java/google/registry/request/auth/AuthenticatedRegistrarAccessorTest.java
+++ b/core/src/test/java/google/registry/request/auth/AuthenticatedRegistrarAccessorTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.AppEngineExtension.THE_REGISTRAR_GAE_USER_
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.LogsSubject.assertAboutLogs;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoInteractions;
diff --git a/core/src/test/java/google/registry/request/auth/RequestAuthenticatorTest.java b/core/src/test/java/google/registry/request/auth/RequestAuthenticatorTest.java
index 85bbe607f..e56751820 100644
--- a/core/src/test/java/google/registry/request/auth/RequestAuthenticatorTest.java
+++ b/core/src/test/java/google/registry/request/auth/RequestAuthenticatorTest.java
@@ -17,7 +17,7 @@ package google.registry.request.auth;
import static com.google.common.net.HttpHeaders.AUTHORIZATION;
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verifyNoInteractions;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/request/lock/LockHandlerImplTest.java b/core/src/test/java/google/registry/request/lock/LockHandlerImplTest.java
index d9b3ce77d..d2c68ba43 100644
--- a/core/src/test/java/google/registry/request/lock/LockHandlerImplTest.java
+++ b/core/src/test/java/google/registry/request/lock/LockHandlerImplTest.java
@@ -15,7 +15,7 @@
package google.registry.request.lock;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/schema/registrar/RegistrarDaoTest.java b/core/src/test/java/google/registry/schema/registrar/RegistrarDaoTest.java
index 0c7353663..608e0cdb1 100644
--- a/core/src/test/java/google/registry/schema/registrar/RegistrarDaoTest.java
+++ b/core/src/test/java/google/registry/schema/registrar/RegistrarDaoTest.java
@@ -17,7 +17,7 @@ package google.registry.schema.registrar;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.model.registrar.Registrar;
diff --git a/core/src/test/java/google/registry/schema/tld/PremiumListDaoTest.java b/core/src/test/java/google/registry/schema/tld/PremiumListDaoTest.java
index fb0342a25..09ad9ee58 100644
--- a/core/src/test/java/google/registry/schema/tld/PremiumListDaoTest.java
+++ b/core/src/test/java/google/registry/schema/tld/PremiumListDaoTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.newRegistry;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.money.CurrencyUnit.JPY;
import static org.joda.money.CurrencyUnit.USD;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import com.googlecode.objectify.Key;
diff --git a/core/src/test/java/google/registry/schema/tld/PremiumListUtilsTest.java b/core/src/test/java/google/registry/schema/tld/PremiumListUtilsTest.java
index d6eca9754..b0c6dbfe4 100644
--- a/core/src/test/java/google/registry/schema/tld/PremiumListUtilsTest.java
+++ b/core/src/test/java/google/registry/schema/tld/PremiumListUtilsTest.java
@@ -16,7 +16,7 @@ package google.registry.schema.tld;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.schema.tld.PremiumListUtils.parseToPremiumList;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.registry.label.PremiumList;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/storage/drive/DriveConnectionTest.java b/core/src/test/java/google/registry/storage/drive/DriveConnectionTest.java
index 180ab5f3e..64c164691 100644
--- a/core/src/test/java/google/registry/storage/drive/DriveConnectionTest.java
+++ b/core/src/test/java/google/registry/storage/drive/DriveConnectionTest.java
@@ -16,7 +16,7 @@ package google.registry.storage.drive;
import static com.google.common.io.ByteStreams.toByteArray;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.argThat;
diff --git a/core/src/test/java/google/registry/testing/AppEngineExtensionTest.java b/core/src/test/java/google/registry/testing/AppEngineExtensionTest.java
index 396a03694..cd4e6be64 100644
--- a/core/src/test/java/google/registry/testing/AppEngineExtensionTest.java
+++ b/core/src/test/java/google/registry/testing/AppEngineExtensionTest.java
@@ -15,10 +15,11 @@
package google.registry.testing;
import static com.google.common.io.Files.asCharSink;
+import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth.assertWithMessage;
import static google.registry.util.CollectionUtils.entriesToImmutableMap;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Joiner;
import com.google.common.collect.Multimap;
@@ -26,6 +27,7 @@ import com.google.common.collect.MultimapBuilder;
import com.google.common.collect.Multimaps;
import com.googlecode.objectify.Key;
import com.googlecode.objectify.annotation.Entity;
+import com.googlecode.objectify.annotation.Id;
import io.github.classgraph.ClassGraph;
import io.github.classgraph.ScanResult;
import java.io.File;
@@ -99,23 +101,23 @@ class AppEngineExtensionTest {
}
@Test
- void testRegisterOfyEntities_failure() throws Exception {
+ void testRegisterOfyEntities_duplicateEntitiesWithSameName_fails() {
AppEngineExtension appEngineRule =
AppEngineExtension.builder()
.withDatastoreAndCloudSql()
- .withOfyTestEntities(
- google.registry.testing.TestObject.class, AppEngineExtensionTestObject.class)
+ .withOfyTestEntities(google.registry.testing.TestObject.class, TestObject.class)
.build();
- String expectedErrorMessage =
- String.format(
- "Cannot register %s. The Kind %s is already registered with %s",
- AppEngineExtensionTestObject.class.getName(),
- "TestObject",
- google.registry.testing.TestObject.class.getName());
- assertThrows(
- expectedErrorMessage,
- IllegalStateException.class,
- () -> appEngineRule.beforeEach(context.getContext()));
+ IllegalStateException thrown =
+ assertThrows(
+ IllegalStateException.class, () -> appEngineRule.beforeEach(context.getContext()));
+ assertThat(thrown)
+ .hasMessageThat()
+ .isEqualTo(
+ String.format(
+ "Cannot register %s. The Kind %s is already registered with %s.",
+ TestObject.class.getName(),
+ "TestObject",
+ google.registry.testing.TestObject.class.getName()));
}
@Test
@@ -128,8 +130,7 @@ class AppEngineExtensionTest {
.scan()) {
Multimap> kindToEntityMultiMap =
scanResult.getClassesWithAnnotation(Entity.class.getName()).stream()
- .filter(
- clazz -> !clazz.getName().equals(AppEngineExtensionTestObject.class.getName()))
+ .filter(clazz -> !clazz.getName().equals(TestObject.class.getName()))
.map(clazz -> clazz.loadClass())
.collect(
Multimaps.toMultimap(
@@ -153,5 +154,7 @@ class AppEngineExtensionTest {
}
@Entity
- private static final class AppEngineExtensionTestObject {}
+ private static final class TestObject {
+ @Id long id;
+ }
}
diff --git a/core/src/test/java/google/registry/testing/InjectExtension.java b/core/src/test/java/google/registry/testing/InjectExtension.java
index 1c792b233..d4693f6dd 100644
--- a/core/src/test/java/google/registry/testing/InjectExtension.java
+++ b/core/src/test/java/google/registry/testing/InjectExtension.java
@@ -107,8 +107,9 @@ public class InjectExtension implements AfterEachCallback {
*
* The field is allowed to be {@code private}, but it most not be {@code final}.
*
- *
This method may be called either from either your {@link org.junit.Before @Before} method or
- * from the {@link org.junit.Test @Test} method itself. However you may not inject the same field
+ *
This method may be called either from either your {@link
+ * org.junit.jupiter.api.BeforeEach @BeforeEach} method or from the {@link
+ * org.junit.jupiter.api.Test @Test} method itself. However you may not inject the same field
* multiple times during the same test.
*
* @throws IllegalArgumentException if the static field could not be found or modified.
diff --git a/core/src/test/java/google/registry/testing/SqlHelper.java b/core/src/test/java/google/registry/testing/SqlHelper.java
index 59bd10d3b..686c94d86 100644
--- a/core/src/test/java/google/registry/testing/SqlHelper.java
+++ b/core/src/test/java/google/registry/testing/SqlHelper.java
@@ -17,7 +17,7 @@ package google.registry.testing;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
import static google.registry.testing.AppEngineExtension.makeRegistrar1;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Throwables;
import com.google.common.collect.ImmutableList;
@@ -26,7 +26,7 @@ import google.registry.schema.domain.RegistryLock;
import java.sql.SQLException;
import java.util.Optional;
import javax.persistence.PersistenceException;
-import org.junit.function.ThrowingRunnable;
+import org.junit.jupiter.api.function.Executable;
/** Static utils for setting up and retrieving test resources from the SQL database. */
public class SqlHelper {
@@ -65,8 +65,8 @@ public class SqlHelper {
() -> jpaTm().saveNew(makeRegistrar1().asBuilder().setClientId(clientId).build()));
}
- public static void assertThrowForeignKeyViolation(ThrowingRunnable runnable) {
- PersistenceException thrown = assertThrows(PersistenceException.class, runnable);
+ public static void assertThrowForeignKeyViolation(Executable executable) {
+ PersistenceException thrown = assertThrows(PersistenceException.class, executable);
assertThat(Throwables.getRootCause(thrown)).isInstanceOf(SQLException.class);
assertThat(Throwables.getRootCause(thrown))
.hasMessageThat()
diff --git a/core/src/test/java/google/registry/testing/sftp/SftpServerRule.java b/core/src/test/java/google/registry/testing/sftp/SftpServerExtension.java
similarity index 92%
rename from core/src/test/java/google/registry/testing/sftp/SftpServerRule.java
rename to core/src/test/java/google/registry/testing/sftp/SftpServerExtension.java
index 29c2234da..29bf14e82 100644
--- a/core/src/test/java/google/registry/testing/sftp/SftpServerRule.java
+++ b/core/src/test/java/google/registry/testing/sftp/SftpServerExtension.java
@@ -25,11 +25,11 @@ import org.junit.jupiter.api.extension.AfterEachCallback;
import org.junit.jupiter.api.extension.ExtensionContext;
/**
- * JUnit Rule for creating an in-process {@link TestSftpServer SFTP Server}.
+ * JUnit extension for creating an in-process {@link TestSftpServer SFTP Server}.
*
* @see TestSftpServer
*/
-public final class SftpServerRule implements AfterEachCallback {
+public final class SftpServerExtension implements AfterEachCallback {
@Nullable
private FtpServer server;
diff --git a/core/src/test/java/google/registry/tldconfig/idn/IdnTableTest.java b/core/src/test/java/google/registry/tldconfig/idn/IdnTableTest.java
index 3fa902fb9..a84c77541 100644
--- a/core/src/test/java/google/registry/tldconfig/idn/IdnTableTest.java
+++ b/core/src/test/java/google/registry/tldconfig/idn/IdnTableTest.java
@@ -15,7 +15,7 @@
package google.registry.tldconfig.idn;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import java.net.URI;
diff --git a/core/src/test/java/google/registry/tmch/LordnLogTest.java b/core/src/test/java/google/registry/tmch/LordnLogTest.java
index cbc483708..dc8a304c4 100644
--- a/core/src/test/java/google/registry/tmch/LordnLogTest.java
+++ b/core/src/test/java/google/registry/tmch/LordnLogTest.java
@@ -15,7 +15,7 @@
package google.registry.tmch;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import google.registry.tmch.LordnLog.Result;
diff --git a/core/src/test/java/google/registry/tmch/LordnTaskUtilsTest.java b/core/src/test/java/google/registry/tmch/LordnTaskUtilsTest.java
index ae7c09893..b6b7a8b16 100644
--- a/core/src/test/java/google/registry/tmch/LordnTaskUtilsTest.java
+++ b/core/src/test/java/google/registry/tmch/LordnTaskUtilsTest.java
@@ -22,7 +22,7 @@ import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistDomainAndEnqueueLordn;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.domain.DomainBase;
import google.registry.model.domain.launch.LaunchNotice;
diff --git a/core/src/test/java/google/registry/tmch/NordnUploadActionTest.java b/core/src/test/java/google/registry/tmch/NordnUploadActionTest.java
index afebc8947..522d06d53 100644
--- a/core/src/test/java/google/registry/tmch/NordnUploadActionTest.java
+++ b/core/src/test/java/google/registry/tmch/NordnUploadActionTest.java
@@ -31,7 +31,7 @@ import static java.nio.charset.StandardCharsets.US_ASCII;
import static java.nio.charset.StandardCharsets.UTF_8;
import static javax.servlet.http.HttpServletResponse.SC_ACCEPTED;
import static javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/tmch/NordnVerifyActionTest.java b/core/src/test/java/google/registry/tmch/NordnVerifyActionTest.java
index 27f55d19a..506826b6a 100644
--- a/core/src/test/java/google/registry/tmch/NordnVerifyActionTest.java
+++ b/core/src/test/java/google/registry/tmch/NordnVerifyActionTest.java
@@ -24,7 +24,7 @@ import static java.nio.charset.StandardCharsets.UTF_8;
import static javax.servlet.http.HttpServletResponse.SC_NO_CONTENT;
import static javax.servlet.http.HttpServletResponse.SC_OK;
import static javax.servlet.http.HttpServletResponse.SC_UNAUTHORIZED;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/tmch/SmdrlCsvParserTest.java b/core/src/test/java/google/registry/tmch/SmdrlCsvParserTest.java
index b8a9090f0..edad1b6ce 100644
--- a/core/src/test/java/google/registry/tmch/SmdrlCsvParserTest.java
+++ b/core/src/test/java/google/registry/tmch/SmdrlCsvParserTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.US_ASCII;
import static org.joda.time.Duration.millis;
import static org.joda.time.Duration.standardDays;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.io.CharSource;
diff --git a/core/src/test/java/google/registry/tmch/TmchCertificateAuthorityTest.java b/core/src/test/java/google/registry/tmch/TmchCertificateAuthorityTest.java
index 462753931..9b4c1e703 100644
--- a/core/src/test/java/google/registry/tmch/TmchCertificateAuthorityTest.java
+++ b/core/src/test/java/google/registry/tmch/TmchCertificateAuthorityTest.java
@@ -20,7 +20,7 @@ import static google.registry.config.RegistryConfig.ConfigModule.TmchCaMode.PROD
import static google.registry.tmch.TmchTestData.loadFile;
import static google.registry.util.ResourceUtils.readResourceUtf8;
import static google.registry.util.X509Utils.loadCertificate;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.tmch.TmchCrl;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/tmch/TmchCrlActionTest.java b/core/src/test/java/google/registry/tmch/TmchCrlActionTest.java
index d8bb6ef65..3e18ab46d 100644
--- a/core/src/test/java/google/registry/tmch/TmchCrlActionTest.java
+++ b/core/src/test/java/google/registry/tmch/TmchCrlActionTest.java
@@ -17,7 +17,7 @@ package google.registry.tmch;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.TestDataHelper.loadBytes;
import static google.registry.util.ResourceUtils.readResourceBytes;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/tmch/TmchXmlSignatureTest.java b/core/src/test/java/google/registry/tmch/TmchXmlSignatureTest.java
index afd3cc0df..ed10c8342 100644
--- a/core/src/test/java/google/registry/tmch/TmchXmlSignatureTest.java
+++ b/core/src/test/java/google/registry/tmch/TmchXmlSignatureTest.java
@@ -16,7 +16,7 @@ package google.registry.tmch;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.tmch.TmchTestData.loadSmd;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.config.RegistryConfig.ConfigModule.TmchCaMode;
import google.registry.testing.AppEngineExtension;
diff --git a/core/src/test/java/google/registry/tools/AuthModuleTest.java b/core/src/test/java/google/registry/tools/AuthModuleTest.java
index 9de23e60a..0081106cc 100644
--- a/core/src/test/java/google/registry/tools/AuthModuleTest.java
+++ b/core/src/test/java/google/registry/tools/AuthModuleTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.when;
import com.google.api.client.auth.oauth2.ClientParametersAuthentication;
diff --git a/core/src/test/java/google/registry/tools/CheckDomainClaimsCommandTest.java b/core/src/test/java/google/registry/tools/CheckDomainClaimsCommandTest.java
index 098c2678e..e98508e7f 100644
--- a/core/src/test/java/google/registry/tools/CheckDomainClaimsCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CheckDomainClaimsCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.model.registrar.Registrar.Type;
diff --git a/core/src/test/java/google/registry/tools/CheckDomainCommandTest.java b/core/src/test/java/google/registry/tools/CheckDomainCommandTest.java
index 986fe67da..d9cb22a5b 100644
--- a/core/src/test/java/google/registry/tools/CheckDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CheckDomainCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.model.registrar.Registrar.Type;
diff --git a/core/src/test/java/google/registry/tools/CreateAnchorTenantCommandTest.java b/core/src/test/java/google/registry/tools/CreateAnchorTenantCommandTest.java
index 2aa379efc..b53b072ea 100644
--- a/core/src/test/java/google/registry/tools/CreateAnchorTenantCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateAnchorTenantCommandTest.java
@@ -17,7 +17,7 @@ package google.registry.tools;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.model.registry.Registry;
diff --git a/core/src/test/java/google/registry/tools/CreateCdnsTldTest.java b/core/src/test/java/google/registry/tools/CreateCdnsTldTest.java
index ed3f68c96..1a6bab409 100644
--- a/core/src/test/java/google/registry/tools/CreateCdnsTldTest.java
+++ b/core/src/test/java/google/registry/tools/CreateCdnsTldTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/tools/CreateContactCommandTest.java b/core/src/test/java/google/registry/tools/CreateContactCommandTest.java
index 04c23d618..457c069d9 100644
--- a/core/src/test/java/google/registry/tools/CreateContactCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateContactCommandTest.java
@@ -14,7 +14,7 @@
package google.registry.tools;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.testing.DeterministicStringGenerator;
diff --git a/core/src/test/java/google/registry/tools/CreateDomainCommandTest.java b/core/src/test/java/google/registry/tools/CreateDomainCommandTest.java
index 374b6a2a5..2e3a6280f 100644
--- a/core/src/test/java/google/registry/tools/CreateDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateDomainCommandTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.model.registry.Registry;
diff --git a/core/src/test/java/google/registry/tools/CreateHostCommandTest.java b/core/src/test/java/google/registry/tools/CreateHostCommandTest.java
index 14102fdaf..a7f1836c4 100644
--- a/core/src/test/java/google/registry/tools/CreateHostCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateHostCommandTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/CreateOrUpdateReservedListCommandTestCase.java b/core/src/test/java/google/registry/tools/CreateOrUpdateReservedListCommandTestCase.java
index b1f94abe0..552f5c4df 100644
--- a/core/src/test/java/google/registry/tools/CreateOrUpdateReservedListCommandTestCase.java
+++ b/core/src/test/java/google/registry/tools/CreateOrUpdateReservedListCommandTestCase.java
@@ -19,7 +19,7 @@ import static google.registry.model.registry.label.ReservationType.FULLY_BLOCKED
import static google.registry.persistence.transaction.TransactionManagerFactory.jpaTm;
import static google.registry.testing.TestDataHelper.loadFile;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/tools/CreatePremiumListCommandTest.java b/core/src/test/java/google/registry/tools/CreatePremiumListCommandTest.java
index 5fc81668f..bb5471307 100644
--- a/core/src/test/java/google/registry/tools/CreatePremiumListCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreatePremiumListCommandTest.java
@@ -17,7 +17,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.request.JsonResponse.JSON_SAFETY_PREFIX;
import static google.registry.testing.TestDataHelper.loadFile;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyMap;
import static org.mockito.ArgumentMatchers.eq;
diff --git a/core/src/test/java/google/registry/tools/CreateRegistrarCommandTest.java b/core/src/test/java/google/registry/tools/CreateRegistrarCommandTest.java
index e5d379e62..419f8700d 100644
--- a/core/src/test/java/google/registry/tools/CreateRegistrarCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateRegistrarCommandTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.CertificateSamples.SAMPLE_CERT_HASH;
import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoInteractions;
diff --git a/core/src/test/java/google/registry/tools/CreateRegistrarGroupsCommandTest.java b/core/src/test/java/google/registry/tools/CreateRegistrarGroupsCommandTest.java
index d78470b68..6ab8d810a 100644
--- a/core/src/test/java/google/registry/tools/CreateRegistrarGroupsCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateRegistrarGroupsCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/tools/CreateReservedListCommandTest.java b/core/src/test/java/google/registry/tools/CreateReservedListCommandTest.java
index 88eb36f49..a37323e80 100644
--- a/core/src/test/java/google/registry/tools/CreateReservedListCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateReservedListCommandTest.java
@@ -22,7 +22,7 @@ import static google.registry.testing.DatastoreHelper.persistReservedList;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.tools.CreateReservedListCommand.INVALID_FORMAT_ERROR_MESSAGE;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import google.registry.model.registry.Registry;
diff --git a/core/src/test/java/google/registry/tools/CreateTldCommandTest.java b/core/src/test/java/google/registry/tools/CreateTldCommandTest.java
index 6cbb4d558..13f192eba 100644
--- a/core/src/test/java/google/registry/tools/CreateTldCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CreateTldCommandTest.java
@@ -27,7 +27,7 @@ import static org.joda.money.CurrencyUnit.JPY;
import static org.joda.money.CurrencyUnit.USD;
import static org.joda.time.DateTimeZone.UTC;
import static org.joda.time.Duration.standardMinutes;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/tools/CurlCommandTest.java b/core/src/test/java/google/registry/tools/CurlCommandTest.java
index 324faf2c1..d3bebea77 100644
--- a/core/src/test/java/google/registry/tools/CurlCommandTest.java
+++ b/core/src/test/java/google/registry/tools/CurlCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.request.Action.Service.DEFAULT;
import static google.registry.request.Action.Service.PUBAPI;
import static google.registry.request.Action.Service.TOOLS;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/tools/DeleteAllocationTokensCommandTest.java b/core/src/test/java/google/registry/tools/DeleteAllocationTokensCommandTest.java
index 664f5c907..9c123bd3b 100644
--- a/core/src/test/java/google/registry/tools/DeleteAllocationTokensCommandTest.java
+++ b/core/src/test/java/google/registry/tools/DeleteAllocationTokensCommandTest.java
@@ -19,7 +19,7 @@ import static google.registry.model.domain.token.AllocationToken.TokenType.SINGL
import static google.registry.model.ofy.ObjectifyService.ofy;
import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.googlecode.objectify.Key;
import google.registry.model.domain.token.AllocationToken;
diff --git a/core/src/test/java/google/registry/tools/DeleteDomainCommandTest.java b/core/src/test/java/google/registry/tools/DeleteDomainCommandTest.java
index 960308d87..5f6e44862 100644
--- a/core/src/test/java/google/registry/tools/DeleteDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/DeleteDomainCommandTest.java
@@ -14,7 +14,7 @@
package google.registry.tools;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/DeleteHostCommandTest.java b/core/src/test/java/google/registry/tools/DeleteHostCommandTest.java
index 5eb4df107..903739b42 100644
--- a/core/src/test/java/google/registry/tools/DeleteHostCommandTest.java
+++ b/core/src/test/java/google/registry/tools/DeleteHostCommandTest.java
@@ -14,7 +14,7 @@
package google.registry.tools;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/DeletePremiumListCommandTest.java b/core/src/test/java/google/registry/tools/DeletePremiumListCommandTest.java
index 6b7d67742..965f37316 100644
--- a/core/src/test/java/google/registry/tools/DeletePremiumListCommandTest.java
+++ b/core/src/test/java/google/registry/tools/DeletePremiumListCommandTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.loadPremiumListEntries;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.registry.Registry;
import google.registry.model.registry.label.PremiumList;
diff --git a/core/src/test/java/google/registry/tools/DeleteReservedListCommandTest.java b/core/src/test/java/google/registry/tools/DeleteReservedListCommandTest.java
index 276f0db6e..937e610f6 100644
--- a/core/src/test/java/google/registry/tools/DeleteReservedListCommandTest.java
+++ b/core/src/test/java/google/registry/tools/DeleteReservedListCommandTest.java
@@ -19,7 +19,7 @@ import static com.google.common.truth.Truth8.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistReservedList;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.registry.Registry;
import google.registry.model.registry.label.ReservedList;
diff --git a/core/src/test/java/google/registry/tools/DeleteTldCommandTest.java b/core/src/test/java/google/registry/tools/DeleteTldCommandTest.java
index d8a4cd8e3..b5eb3752e 100644
--- a/core/src/test/java/google/registry/tools/DeleteTldCommandTest.java
+++ b/core/src/test/java/google/registry/tools/DeleteTldCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.newRegistry;
import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Ascii;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/tools/DomainLockUtilsTest.java b/core/src/test/java/google/registry/tools/DomainLockUtilsTest.java
index 59d128788..0a09336c9 100644
--- a/core/src/test/java/google/registry/tools/DomainLockUtilsTest.java
+++ b/core/src/test/java/google/registry/tools/DomainLockUtilsTest.java
@@ -31,7 +31,7 @@ import static google.registry.tools.LockOrUnlockDomainCommand.REGISTRY_LOCK_STAT
import static org.joda.time.Duration.standardDays;
import static org.joda.time.Duration.standardHours;
import static org.joda.time.Duration.standardSeconds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/tools/EppToolCommandTest.java b/core/src/test/java/google/registry/tools/EppToolCommandTest.java
index 80589f88f..24a0267e9 100644
--- a/core/src/test/java/google/registry/tools/EppToolCommandTest.java
+++ b/core/src/test/java/google/registry/tools/EppToolCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.Parameter;
import com.beust.jcommander.Parameters;
diff --git a/core/src/test/java/google/registry/tools/ExecuteEppCommandTest.java b/core/src/test/java/google/registry/tools/ExecuteEppCommandTest.java
index fa3b3281f..4108b913e 100644
--- a/core/src/test/java/google/registry/tools/ExecuteEppCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ExecuteEppCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.tools.server.ToolsTestData;
diff --git a/core/src/test/java/google/registry/tools/GenerateAllocationTokensCommandTest.java b/core/src/test/java/google/registry/tools/GenerateAllocationTokensCommandTest.java
index e1318c72e..302ba1939 100644
--- a/core/src/test/java/google/registry/tools/GenerateAllocationTokensCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GenerateAllocationTokensCommandTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static java.nio.charset.StandardCharsets.UTF_8;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.spy;
import static org.mockito.Mockito.times;
diff --git a/core/src/test/java/google/registry/tools/GenerateDnsReportCommandTest.java b/core/src/test/java/google/registry/tools/GenerateDnsReportCommandTest.java
index eb85102f1..c0e2410d2 100644
--- a/core/src/test/java/google/registry/tools/GenerateDnsReportCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GenerateDnsReportCommandTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistResource;
import static java.nio.charset.StandardCharsets.UTF_8;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/GenerateEscrowDepositCommandTest.java b/core/src/test/java/google/registry/tools/GenerateEscrowDepositCommandTest.java
index 1e2016bb7..3eb4cdb60 100644
--- a/core/src/test/java/google/registry/tools/GenerateEscrowDepositCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GenerateEscrowDepositCommandTest.java
@@ -18,7 +18,7 @@ import static com.google.appengine.api.taskqueue.QueueFactory.getQueue;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.TaskQueueHelper.assertTasksEnqueued;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.when;
import com.beust.jcommander.ParameterException;
diff --git a/core/src/test/java/google/registry/tools/GetAllocationTokenCommandTest.java b/core/src/test/java/google/registry/tools/GetAllocationTokenCommandTest.java
index 4d64b7106..56cecb96a 100644
--- a/core/src/test/java/google/registry/tools/GetAllocationTokenCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetAllocationTokenCommandTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResources;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/GetContactCommandTest.java b/core/src/test/java/google/registry/tools/GetContactCommandTest.java
index 1f8f17002..069d3ec4f 100644
--- a/core/src/test/java/google/registry/tools/GetContactCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetContactCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveContact;
import static google.registry.testing.DatastoreHelper.persistDeletedContact;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.DateTime;
diff --git a/core/src/test/java/google/registry/tools/GetDomainCommandTest.java b/core/src/test/java/google/registry/tools/GetDomainCommandTest.java
index 04aa2548b..5f5e2db3c 100644
--- a/core/src/test/java/google/registry/tools/GetDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetDomainCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.DateTime;
diff --git a/core/src/test/java/google/registry/tools/GetHostCommandTest.java b/core/src/test/java/google/registry/tools/GetHostCommandTest.java
index 3932a812e..23fc0061e 100644
--- a/core/src/test/java/google/registry/tools/GetHostCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetHostCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistDeletedHost;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.DateTime;
diff --git a/core/src/test/java/google/registry/tools/GetOperationStatusCommandTest.java b/core/src/test/java/google/registry/tools/GetOperationStatusCommandTest.java
index 8358eae97..1d4272c15 100644
--- a/core/src/test/java/google/registry/tools/GetOperationStatusCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetOperationStatusCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.when;
import google.registry.export.datastore.DatastoreAdmin;
diff --git a/core/src/test/java/google/registry/tools/GetRegistrarCommandTest.java b/core/src/test/java/google/registry/tools/GetRegistrarCommandTest.java
index f70eadb65..9d4a85148 100644
--- a/core/src/test/java/google/registry/tools/GetRegistrarCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetRegistrarCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/GetResourceByKeyCommandTest.java b/core/src/test/java/google/registry/tools/GetResourceByKeyCommandTest.java
index 9bf649247..a3efdab71 100644
--- a/core/src/test/java/google/registry/tools/GetResourceByKeyCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetResourceByKeyCommandTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.persistDeletedContact;
import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistDeletedHost;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.DateTime;
diff --git a/core/src/test/java/google/registry/tools/GetTldCommandTest.java b/core/src/test/java/google/registry/tools/GetTldCommandTest.java
index 82dc63a43..33e7bd8d2 100644
--- a/core/src/test/java/google/registry/tools/GetTldCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GetTldCommandTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.createTlds;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/GhostrydeCommandTest.java b/core/src/test/java/google/registry/tools/GhostrydeCommandTest.java
index 01ee300d2..a344557ee 100644
--- a/core/src/test/java/google/registry/tools/GhostrydeCommandTest.java
+++ b/core/src/test/java/google/registry/tools/GhostrydeCommandTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.keyring.api.Keyring;
import google.registry.rde.Ghostryde;
diff --git a/core/src/test/java/google/registry/tools/ImportDatastoreCommandTest.java b/core/src/test/java/google/registry/tools/ImportDatastoreCommandTest.java
index 414b33861..462d93c22 100644
--- a/core/src/test/java/google/registry/tools/ImportDatastoreCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ImportDatastoreCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.Mockito.never;
import static org.mockito.Mockito.times;
diff --git a/core/src/test/java/google/registry/tools/ListCursorsCommandTest.java b/core/src/test/java/google/registry/tools/ListCursorsCommandTest.java
index 0d976c054..e0977f4cc 100644
--- a/core/src/test/java/google/registry/tools/ListCursorsCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ListCursorsCommandTest.java
@@ -17,7 +17,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.model.common.Cursor;
diff --git a/core/src/test/java/google/registry/tools/ListDomainsCommandTest.java b/core/src/test/java/google/registry/tools/ListDomainsCommandTest.java
index ee0a5a06e..2a5e1619e 100644
--- a/core/src/test/java/google/registry/tools/ListDomainsCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ListDomainsCommandTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.newRegistry;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/tools/LockDomainCommandTest.java b/core/src/test/java/google/registry/tools/LockDomainCommandTest.java
index 7b10251fe..29d7627f7 100644
--- a/core/src/test/java/google/registry/tools/LockDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/LockDomainCommandTest.java
@@ -23,7 +23,7 @@ import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.SqlHelper.getMostRecentRegistryLockByRepoId;
import static google.registry.tools.LockOrUnlockDomainCommand.REGISTRY_LOCK_STATUSES;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/MutatingCommandTest.java b/core/src/test/java/google/registry/tools/MutatingCommandTest.java
index c9ec15c0c..0ef3e5615 100644
--- a/core/src/test/java/google/registry/tools/MutatingCommandTest.java
+++ b/core/src/test/java/google/registry/tools/MutatingCommandTest.java
@@ -22,7 +22,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.host.HostResource;
import google.registry.model.registrar.Registrar;
diff --git a/core/src/test/java/google/registry/tools/MutatingEppToolCommandTest.java b/core/src/test/java/google/registry/tools/MutatingEppToolCommandTest.java
index 83690c9c2..1cc9ad07c 100644
--- a/core/src/test/java/google/registry/tools/MutatingEppToolCommandTest.java
+++ b/core/src/test/java/google/registry/tools/MutatingEppToolCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.Parameter;
import com.beust.jcommander.Parameters;
diff --git a/core/src/test/java/google/registry/tools/NonMutatingEppToolCommandTest.java b/core/src/test/java/google/registry/tools/NonMutatingEppToolCommandTest.java
index 4e65fcd17..d853951d4 100644
--- a/core/src/test/java/google/registry/tools/NonMutatingEppToolCommandTest.java
+++ b/core/src/test/java/google/registry/tools/NonMutatingEppToolCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.Parameter;
import com.beust.jcommander.Parameters;
diff --git a/core/src/test/java/google/registry/tools/RegistrarContactCommandTest.java b/core/src/test/java/google/registry/tools/RegistrarContactCommandTest.java
index b835e66eb..a7ff62838 100644
--- a/core/src/test/java/google/registry/tools/RegistrarContactCommandTest.java
+++ b/core/src/test/java/google/registry/tools/RegistrarContactCommandTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResource;
import static google.registry.testing.DatastoreHelper.persistSimpleResources;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/tools/RegistryToolEnvironmentTest.java b/core/src/test/java/google/registry/tools/RegistryToolEnvironmentTest.java
index 40cdbc5f0..ae1f2f70a 100644
--- a/core/src/test/java/google/registry/tools/RegistryToolEnvironmentTest.java
+++ b/core/src/test/java/google/registry/tools/RegistryToolEnvironmentTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.testing.SystemPropertyExtension;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/RegistryToolTest.java b/core/src/test/java/google/registry/tools/RegistryToolTest.java
index ef34848d5..33f2ffd0d 100644
--- a/core/src/test/java/google/registry/tools/RegistryToolTest.java
+++ b/core/src/test/java/google/registry/tools/RegistryToolTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.testing.AppEngineExtension;
import java.io.ByteArrayOutputStream;
diff --git a/core/src/test/java/google/registry/tools/RenewDomainCommandTest.java b/core/src/test/java/google/registry/tools/RenewDomainCommandTest.java
index 72141c16f..b4634ea3e 100644
--- a/core/src/test/java/google/registry/tools/RenewDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/RenewDomainCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/tools/SetNumInstancesCommandTest.java b/core/src/test/java/google/registry/tools/SetNumInstancesCommandTest.java
index 141b76ae5..6a5e6033e 100644
--- a/core/src/test/java/google/registry/tools/SetNumInstancesCommandTest.java
+++ b/core/src/test/java/google/registry/tools/SetNumInstancesCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/tools/SetupOteCommandTest.java b/core/src/test/java/google/registry/tools/SetupOteCommandTest.java
index 5179b15fd..a5283375c 100644
--- a/core/src/test/java/google/registry/tools/SetupOteCommandTest.java
+++ b/core/src/test/java/google/registry/tools/SetupOteCommandTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/ShellCommandTest.java b/core/src/test/java/google/registry/tools/ShellCommandTest.java
index 27baa997b..4dd2b0132 100644
--- a/core/src/test/java/google/registry/tools/ShellCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ShellCommandTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/tools/UniformRapidSuspensionCommandTest.java b/core/src/test/java/google/registry/tools/UniformRapidSuspensionCommandTest.java
index 184b340f7..15e73ddb6 100644
--- a/core/src/test/java/google/registry/tools/UniformRapidSuspensionCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UniformRapidSuspensionCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/tools/UnlockDomainCommandTest.java b/core/src/test/java/google/registry/tools/UnlockDomainCommandTest.java
index 2ab272fbe..32ab19b77 100644
--- a/core/src/test/java/google/registry/tools/UnlockDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UnlockDomainCommandTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.persistNewRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.SqlHelper.getMostRecentRegistryLockByRepoId;
import static google.registry.tools.LockOrUnlockDomainCommand.REGISTRY_LOCK_STATUSES;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/UnrenewDomainCommandTest.java b/core/src/test/java/google/registry/tools/UnrenewDomainCommandTest.java
index 6011ebe79..d0ff335a2 100644
--- a/core/src/test/java/google/registry/tools/UnrenewDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UnrenewDomainCommandTest.java
@@ -32,7 +32,7 @@ import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static google.registry.testing.DatastoreHelper.persistDomainWithDependentResources;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.HistoryEntrySubject.assertAboutHistoryEntries;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.googlecode.objectify.Key;
diff --git a/core/src/test/java/google/registry/tools/UpdateAllocationTokensCommandTest.java b/core/src/test/java/google/registry/tools/UpdateAllocationTokensCommandTest.java
index 50df48084..cf19272f7 100644
--- a/core/src/test/java/google/registry/tools/UpdateAllocationTokensCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateAllocationTokensCommandTest.java
@@ -24,7 +24,7 @@ import static google.registry.model.domain.token.AllocationToken.TokenType.UNLIM
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableSortedMap;
diff --git a/core/src/test/java/google/registry/tools/UpdateCursorsCommandTest.java b/core/src/test/java/google/registry/tools/UpdateCursorsCommandTest.java
index 7586f8f32..49a2aca39 100644
--- a/core/src/test/java/google/registry/tools/UpdateCursorsCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateCursorsCommandTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.model.ofy.ObjectifyService.ofy;
import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.model.common.Cursor;
diff --git a/core/src/test/java/google/registry/tools/UpdateDomainCommandTest.java b/core/src/test/java/google/registry/tools/UpdateDomainCommandTest.java
index 192890955..77018d0d7 100644
--- a/core/src/test/java/google/registry/tools/UpdateDomainCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateDomainCommandTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.DatastoreHelper.newContactResource;
import static google.registry.testing.DatastoreHelper.newDomainBase;
import static google.registry.testing.DatastoreHelper.persistActiveHost;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/tools/UpdateRegistrarCommandTest.java b/core/src/test/java/google/registry/tools/UpdateRegistrarCommandTest.java
index 65ab5cb17..e3507f04f 100644
--- a/core/src/test/java/google/registry/tools/UpdateRegistrarCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateRegistrarCommandTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/UpdateReservedListCommandTest.java b/core/src/test/java/google/registry/tools/UpdateReservedListCommandTest.java
index c9bf3ebb4..0b036132d 100644
--- a/core/src/test/java/google/registry/tools/UpdateReservedListCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateReservedListCommandTest.java
@@ -19,7 +19,7 @@ import static com.google.common.truth.Truth8.assertThat;
import static google.registry.model.registry.label.ReservationType.FULLY_BLOCKED;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.util.DateTimeUtils.START_OF_TIME;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
diff --git a/core/src/test/java/google/registry/tools/UpdateServerLocksCommandTest.java b/core/src/test/java/google/registry/tools/UpdateServerLocksCommandTest.java
index e05df9d78..b96822c65 100644
--- a/core/src/test/java/google/registry/tools/UpdateServerLocksCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateServerLocksCommandTest.java
@@ -14,7 +14,7 @@
package google.registry.tools;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/UpdateTldCommandTest.java b/core/src/test/java/google/registry/tools/UpdateTldCommandTest.java
index df7cb1d05..25794fdcd 100644
--- a/core/src/test/java/google/registry/tools/UpdateTldCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UpdateTldCommandTest.java
@@ -30,7 +30,7 @@ import static org.joda.money.CurrencyUnit.JPY;
import static org.joda.money.CurrencyUnit.USD;
import static org.joda.time.DateTimeZone.UTC;
import static org.joda.time.Duration.standardMinutes;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/tools/UploadClaimsListCommandTest.java b/core/src/test/java/google/registry/tools/UploadClaimsListCommandTest.java
index 3243d4637..f5204d52f 100644
--- a/core/src/test/java/google/registry/tools/UploadClaimsListCommandTest.java
+++ b/core/src/test/java/google/registry/tools/UploadClaimsListCommandTest.java
@@ -16,7 +16,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.tmch.ClaimsListShard;
import java.io.FileNotFoundException;
diff --git a/core/src/test/java/google/registry/tools/ValidateEscrowDepositCommandTest.java b/core/src/test/java/google/registry/tools/ValidateEscrowDepositCommandTest.java
index 4edc719e0..bcd559697 100644
--- a/core/src/test/java/google/registry/tools/ValidateEscrowDepositCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ValidateEscrowDepositCommandTest.java
@@ -15,7 +15,7 @@
package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.rde.RdeTestData;
import google.registry.xml.XmlException;
diff --git a/core/src/test/java/google/registry/tools/ValidateLoginCredentialsCommandTest.java b/core/src/test/java/google/registry/tools/ValidateLoginCredentialsCommandTest.java
index e4437dd7d..7ebd3e2c3 100644
--- a/core/src/test/java/google/registry/tools/ValidateLoginCredentialsCommandTest.java
+++ b/core/src/test/java/google/registry/tools/ValidateLoginCredentialsCommandTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.createTld;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.EppExceptionSubject.assertAboutEppExceptions;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import com.google.common.collect.ImmutableList;
diff --git a/core/src/test/java/google/registry/tools/VerifyOteCommandTest.java b/core/src/test/java/google/registry/tools/VerifyOteCommandTest.java
index 97702fca7..9b7337e88 100644
--- a/core/src/test/java/google/registry/tools/VerifyOteCommandTest.java
+++ b/core/src/test/java/google/registry/tools/VerifyOteCommandTest.java
@@ -17,7 +17,7 @@ package google.registry.tools;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.loadRegistrar;
import static google.registry.testing.DatastoreHelper.persistResource;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.anyMap;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.eq;
diff --git a/core/src/test/java/google/registry/tools/javascrap/BackfillRegistryLocksCommandTest.java b/core/src/test/java/google/registry/tools/javascrap/BackfillRegistryLocksCommandTest.java
index 03a62a298..730157035 100644
--- a/core/src/test/java/google/registry/tools/javascrap/BackfillRegistryLocksCommandTest.java
+++ b/core/src/test/java/google/registry/tools/javascrap/BackfillRegistryLocksCommandTest.java
@@ -25,7 +25,7 @@ import static google.registry.testing.SqlHelper.getMostRecentVerifiedRegistryLoc
import static google.registry.testing.SqlHelper.getRegistryLocksByRegistrarId;
import static google.registry.testing.SqlHelper.saveRegistryLock;
import static google.registry.tools.LockOrUnlockDomainCommand.REGISTRY_LOCK_STATUSES;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
diff --git a/core/src/test/java/google/registry/tools/params/DateParameterTest.java b/core/src/test/java/google/registry/tools/params/DateParameterTest.java
index fbfa7c962..3e1b7d911 100644
--- a/core/src/test/java/google/registry/tools/params/DateParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/DateParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.joda.time.DateTime;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/params/DateTimeParameterTest.java b/core/src/test/java/google/registry/tools/params/DateTimeParameterTest.java
index c90da27bb..41da7728d 100644
--- a/core/src/test/java/google/registry/tools/params/DateTimeParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/DateTimeParameterTest.java
@@ -16,7 +16,7 @@ package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.DateTime;
diff --git a/core/src/test/java/google/registry/tools/params/DurationParameterTest.java b/core/src/test/java/google/registry/tools/params/DurationParameterTest.java
index 328d79489..f42233fda 100644
--- a/core/src/test/java/google/registry/tools/params/DurationParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/DurationParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.Duration;
diff --git a/core/src/test/java/google/registry/tools/params/EnumParameterTest.java b/core/src/test/java/google/registry/tools/params/EnumParameterTest.java
index 3634f0552..0cadee0f9 100644
--- a/core/src/test/java/google/registry/tools/params/EnumParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/EnumParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.model.registry.Registry.TldState;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/params/IntervalParameterTest.java b/core/src/test/java/google/registry/tools/params/IntervalParameterTest.java
index 3e36df98b..ea50681b4 100644
--- a/core/src/test/java/google/registry/tools/params/IntervalParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/IntervalParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.DateTime;
diff --git a/core/src/test/java/google/registry/tools/params/KeyValueMapParameterTest.java b/core/src/test/java/google/registry/tools/params/KeyValueMapParameterTest.java
index f5bf94fa5..6b49a728d 100644
--- a/core/src/test/java/google/registry/tools/params/KeyValueMapParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/KeyValueMapParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableMap;
import google.registry.tools.params.KeyValueMapParameter.CurrencyUnitToStringMap;
diff --git a/core/src/test/java/google/registry/tools/params/MoneyParameterTest.java b/core/src/test/java/google/registry/tools/params/MoneyParameterTest.java
index c628bec5e..ada766ff7 100644
--- a/core/src/test/java/google/registry/tools/params/MoneyParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/MoneyParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.money.Money;
diff --git a/core/src/test/java/google/registry/tools/params/NameserversParameterTest.java b/core/src/test/java/google/registry/tools/params/NameserversParameterTest.java
index bcb1f7daa..00816a2ce 100644
--- a/core/src/test/java/google/registry/tools/params/NameserversParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/NameserversParameterTest.java
@@ -17,7 +17,7 @@ package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
import static google.registry.tools.params.NameserversParameter.splitNameservers;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/params/PathParameterTest.java b/core/src/test/java/google/registry/tools/params/PathParameterTest.java
index b78e4b4cf..644137b2f 100644
--- a/core/src/test/java/google/registry/tools/params/PathParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/PathParameterTest.java
@@ -15,13 +15,9 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.hamcrest.Matchers.equalTo;
-import static org.hamcrest.Matchers.is;
-import static org.hamcrest.Matchers.not;
-import static org.hamcrest.Matchers.startsWith;
-import static org.junit.Assert.assertThrows;
-import static org.junit.Assume.assumeThat;
-import static org.junit.Assume.assumeTrue;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assumptions.assumeFalse;
+import static org.junit.jupiter.api.Assumptions.assumeTrue;
import com.beust.jcommander.ParameterException;
import java.io.File;
@@ -62,8 +58,8 @@ class PathParameterTest {
Path currentDirectory = Paths.get("").toAbsolutePath();
Path file = Paths.get(tmpDir.resolve("tmp.file").toString());
Path relative = file.relativize(currentDirectory);
- assumeThat(relative, is(not(equalTo(file))));
- assumeThat(relative.toString(), startsWith("../"));
+ assumeFalse(relative.equals(file));
+ assumeTrue(relative.toString().startsWith("../"));
Path converted = vanilla.convert(file.toString());
assertThat((Object) converted).isEqualTo(file);
}
diff --git a/core/src/test/java/google/registry/tools/params/PhoneNumberParameterTest.java b/core/src/test/java/google/registry/tools/params/PhoneNumberParameterTest.java
index 97597bc88..b91019ca7 100644
--- a/core/src/test/java/google/registry/tools/params/PhoneNumberParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/PhoneNumberParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth8.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/tools/params/YearMonthParameterTest.java b/core/src/test/java/google/registry/tools/params/YearMonthParameterTest.java
index 66f2cf7b0..1924e9feb 100644
--- a/core/src/test/java/google/registry/tools/params/YearMonthParameterTest.java
+++ b/core/src/test/java/google/registry/tools/params/YearMonthParameterTest.java
@@ -15,7 +15,7 @@
package google.registry.tools.params;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import org.joda.time.YearMonth;
diff --git a/core/src/test/java/google/registry/tools/server/CreateGroupsActionTest.java b/core/src/test/java/google/registry/tools/server/CreateGroupsActionTest.java
index 7e4d934e9..6352936f9 100644
--- a/core/src/test/java/google/registry/tools/server/CreateGroupsActionTest.java
+++ b/core/src/test/java/google/registry/tools/server/CreateGroupsActionTest.java
@@ -16,7 +16,7 @@ package google.registry.tools.server;
import static com.google.common.truth.Truth.assertThat;
import static javax.servlet.http.HttpServletResponse.SC_OK;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/tools/server/DeleteEntityActionTest.java b/core/src/test/java/google/registry/tools/server/DeleteEntityActionTest.java
index 8a4eaed6e..24a3bf738 100644
--- a/core/src/test/java/google/registry/tools/server/DeleteEntityActionTest.java
+++ b/core/src/test/java/google/registry/tools/server/DeleteEntityActionTest.java
@@ -18,7 +18,7 @@ import static com.google.appengine.api.datastore.DatastoreServiceFactory.getData
import static com.google.common.truth.Truth.assertThat;
import static com.googlecode.objectify.Key.create;
import static google.registry.model.ofy.ObjectifyService.ofy;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.appengine.api.datastore.Entity;
import com.google.appengine.api.datastore.KeyFactory;
diff --git a/core/src/test/java/google/registry/tools/server/RefreshDnsForAllDomainsActionTest.java b/core/src/test/java/google/registry/tools/server/RefreshDnsForAllDomainsActionTest.java
index 387a50b92..8b96bf18a 100644
--- a/core/src/test/java/google/registry/tools/server/RefreshDnsForAllDomainsActionTest.java
+++ b/core/src/test/java/google/registry/tools/server/RefreshDnsForAllDomainsActionTest.java
@@ -20,7 +20,7 @@ import static google.registry.testing.DatastoreHelper.persistActiveDomain;
import static google.registry.testing.DatastoreHelper.persistDeletedDomain;
import static org.joda.time.DateTimeZone.UTC;
import static org.joda.time.Duration.standardMinutes;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.never;
diff --git a/core/src/test/java/google/registry/ui/forms/FormFieldExceptionTest.java b/core/src/test/java/google/registry/ui/forms/FormFieldExceptionTest.java
index fc389133c..de46c893b 100644
--- a/core/src/test/java/google/registry/ui/forms/FormFieldExceptionTest.java
+++ b/core/src/test/java/google/registry/ui/forms/FormFieldExceptionTest.java
@@ -15,7 +15,7 @@
package google.registry.ui.forms;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.testing.NullPointerTester;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/ui/forms/FormFieldTest.java b/core/src/test/java/google/registry/ui/forms/FormFieldTest.java
index 0e504156a..b1704541c 100644
--- a/core/src/test/java/google/registry/ui/forms/FormFieldTest.java
+++ b/core/src/test/java/google/registry/ui/forms/FormFieldTest.java
@@ -21,7 +21,7 @@ import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.CharMatcher;
import com.google.common.base.Splitter;
diff --git a/core/src/test/java/google/registry/ui/forms/FormFieldsTest.java b/core/src/test/java/google/registry/ui/forms/FormFieldsTest.java
index 4918ab0e6..878464f2a 100644
--- a/core/src/test/java/google/registry/ui/forms/FormFieldsTest.java
+++ b/core/src/test/java/google/registry/ui/forms/FormFieldsTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth8.assertThat;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.testing.NullPointerTester;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/ui/server/RegistrarFormFieldsTest.java b/core/src/test/java/google/registry/ui/server/RegistrarFormFieldsTest.java
index faae2df22..84f37ad52 100644
--- a/core/src/test/java/google/registry/ui/server/RegistrarFormFieldsTest.java
+++ b/core/src/test/java/google/registry/ui/server/RegistrarFormFieldsTest.java
@@ -17,7 +17,7 @@ package google.registry.ui.server;
import static com.google.common.truth.Truth8.assertThat;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.testing.CertificateSamples;
import google.registry.ui.forms.FormFieldException;
diff --git a/core/src/test/java/google/registry/ui/server/registrar/ConsoleOteSetupActionTest.java b/core/src/test/java/google/registry/ui/server/registrar/ConsoleOteSetupActionTest.java
index 23ebb4a70..916443898 100644
--- a/core/src/test/java/google/registry/ui/server/registrar/ConsoleOteSetupActionTest.java
+++ b/core/src/test/java/google/registry/ui/server/registrar/ConsoleOteSetupActionTest.java
@@ -20,7 +20,7 @@ import static com.google.common.truth.Truth8.assertThat;
import static google.registry.model.registrar.Registrar.loadByClientId;
import static google.registry.testing.DatastoreHelper.persistPremiumList;
import static javax.servlet.http.HttpServletResponse.SC_MOVED_TEMPORARILY;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
diff --git a/core/src/test/java/google/registry/ui/server/registrar/RegistryLockGetActionTest.java b/core/src/test/java/google/registry/ui/server/registrar/RegistryLockGetActionTest.java
index 37c3e416b..c71f7b7b0 100644
--- a/core/src/test/java/google/registry/ui/server/registrar/RegistryLockGetActionTest.java
+++ b/core/src/test/java/google/registry/ui/server/registrar/RegistryLockGetActionTest.java
@@ -24,7 +24,7 @@ import static google.registry.testing.DatastoreHelper.persistResource;
import static google.registry.testing.SqlHelper.saveRegistryLock;
import static javax.servlet.http.HttpServletResponse.SC_FORBIDDEN;
import static javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.api.client.http.HttpStatusCodes;
import com.google.appengine.api.users.User;
diff --git a/core/src/test/java/google/registry/util/ConcurrentTest.java b/core/src/test/java/google/registry/util/ConcurrentTest.java
index 45e24bdb4..3b6d81e16 100644
--- a/core/src/test/java/google/registry/util/ConcurrentTest.java
+++ b/core/src/test/java/google/registry/util/ConcurrentTest.java
@@ -15,7 +15,7 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.testing.NullPointerTester;
diff --git a/core/src/test/java/google/registry/util/TaskQueueUtilsTest.java b/core/src/test/java/google/registry/util/TaskQueueUtilsTest.java
index 9c2675b89..6fa342fe8 100644
--- a/core/src/test/java/google/registry/util/TaskQueueUtilsTest.java
+++ b/core/src/test/java/google/registry/util/TaskQueueUtilsTest.java
@@ -17,7 +17,7 @@ package google.registry.util;
import static com.google.appengine.api.taskqueue.TaskOptions.Builder.withUrl;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.TaskQueueHelper.getQueueInfo;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
diff --git a/core/src/test/java/google/registry/util/UrlFetchUtilsTest.java b/core/src/test/java/google/registry/util/UrlFetchUtilsTest.java
index c39f81a5b..d425347c9 100644
--- a/core/src/test/java/google/registry/util/UrlFetchUtilsTest.java
+++ b/core/src/test/java/google/registry/util/UrlFetchUtilsTest.java
@@ -20,7 +20,7 @@ import static com.google.common.net.MediaType.CSV_UTF_8;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.util.UrlFetchUtils.setPayloadMultipart;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.doAnswer;
import static org.mockito.Mockito.mock;
diff --git a/core/src/test/java/google/registry/whois/WhoisHttpActionTest.java b/core/src/test/java/google/registry/whois/WhoisHttpActionTest.java
index 266ec2505..23a1f08e1 100644
--- a/core/src/test/java/google/registry/whois/WhoisHttpActionTest.java
+++ b/core/src/test/java/google/registry/whois/WhoisHttpActionTest.java
@@ -29,7 +29,7 @@ import static google.registry.whois.WhoisTestData.loadFile;
import static javax.servlet.http.HttpServletResponse.SC_BAD_REQUEST;
import static javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
import static javax.servlet.http.HttpServletResponse.SC_OK;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.mock;
diff --git a/core/src/test/java/google/registry/whois/WhoisReaderTest.java b/core/src/test/java/google/registry/whois/WhoisReaderTest.java
index f4ab60e5b..a965a910c 100644
--- a/core/src/test/java/google/registry/whois/WhoisReaderTest.java
+++ b/core/src/test/java/google/registry/whois/WhoisReaderTest.java
@@ -17,7 +17,7 @@ package google.registry.whois;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.testing.DatastoreHelper.createTlds;
import static google.registry.testing.LogsSubject.assertAboutLogs;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.flogger.LoggerConfig;
import com.google.common.testing.TestLogHandler;
diff --git a/core/src/test/java/google/registry/xjc/XjcObjectTest.java b/core/src/test/java/google/registry/xjc/XjcObjectTest.java
index 0fa7309d1..ffa94a778 100644
--- a/core/src/test/java/google/registry/xjc/XjcObjectTest.java
+++ b/core/src/test/java/google/registry/xjc/XjcObjectTest.java
@@ -21,7 +21,7 @@ import static google.registry.testing.TestDataHelper.loadFile;
import static google.registry.xjc.XjcXmlTransformer.unmarshal;
import static java.nio.charset.StandardCharsets.UTF_16;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.re2j.Pattern;
import google.registry.xjc.rde.XjcRdeDeposit;
diff --git a/core/src/test/java/google/registry/xjc/XmlTestdataTest.java b/core/src/test/java/google/registry/xjc/XmlTestdataTest.java
index 92e832e81..a1ba417e4 100644
--- a/core/src/test/java/google/registry/xjc/XmlTestdataTest.java
+++ b/core/src/test/java/google/registry/xjc/XmlTestdataTest.java
@@ -15,133 +15,111 @@
package google.registry.xjc;
import static com.google.common.truth.Truth.assertThat;
+import static google.registry.testing.TestDataHelper.loadFile;
import static google.registry.xjc.XjcXmlTransformer.unmarshal;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
-import google.registry.testing.TestDataHelper;
import google.registry.xjc.epp.XjcEpp;
import google.registry.xjc.rde.XjcRdeDeposit;
+import google.registry.xml.XmlException;
import java.io.ByteArrayInputStream;
-import org.junit.experimental.theories.DataPoints;
-import org.junit.experimental.theories.Theories;
-import org.junit.experimental.theories.Theory;
-import org.junit.runner.RunWith;
+import java.util.stream.Stream;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.Arguments;
+import org.junit.jupiter.params.provider.MethodSource;
/**
- * Unit tests that ensure {@link XjcObject} is able to unmarshal XML in {@code testdata/} and
- * ensure they conform to the XML schema definitions.
+ * Unit tests that ensure {@link XjcObject} is able to unmarshal XML in {@code testdata/} and ensure
+ * they conform to the XML schema definitions.
*/
-@RunWith(Theories.class)
-public class XmlTestdataTest {
- private static class Example {
- final ByteArrayInputStream xmlStream;
+class XmlTestdataTest {
- private Example(String filename) {
- this.xmlStream = new ByteArrayInputStream(
- TestDataHelper.loadFile(XmlTestdataTest.class, filename).getBytes(UTF_8));
- }
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testValid(String filename, Class extends XjcObject> expectedClazz) throws Exception {
+ XjcObject xml = unmarshal(XjcObject.class, loadAsStream(filename));
+ assertThat(xml).isInstanceOf(expectedClazz);
}
- private static class Good extends Example {
- final Class> clazz;
-
- private Good(String filename, Class> clazz) {
- super(filename);
- this.clazz = clazz;
- }
+ @Test
+ void testInvalid() {
+ ByteArrayInputStream badData = loadAsStream("invalid_greeting.xml");
+ XmlException thrown =
+ assertThrows(XmlException.class, () -> unmarshal(XjcObject.class, badData));
+ assertThat(thrown).hasMessageThat().contains("dcp}' is expected");
}
- private static class Evil extends Example {
- final String error;
-
- private Evil(String filename, String error) {
- super(filename);
- this.error = error;
- }
+ @SuppressWarnings("unused")
+ static Stream provideTestCombinations() {
+ return Stream.of(
+ Arguments.of("contact_check_response.xml", XjcEpp.class),
+ Arguments.of("contact_check.xml", XjcEpp.class),
+ Arguments.of("contact_create_response_offline_review_completed.xml", XjcEpp.class),
+ Arguments.of("contact_create_response_offline_review.xml", XjcEpp.class),
+ Arguments.of("contact_create_response.xml", XjcEpp.class),
+ Arguments.of("contact_create.xml", XjcEpp.class),
+ Arguments.of("contact_delete_response.xml", XjcEpp.class),
+ Arguments.of("contact_delete.xml", XjcEpp.class),
+ Arguments.of("contact_info_response.xml", XjcEpp.class),
+ Arguments.of("contact_info.xml", XjcEpp.class),
+ Arguments.of("contact_transfer_query_response.xml", XjcEpp.class),
+ Arguments.of("contact_transfer_query.xml", XjcEpp.class),
+ Arguments.of("contact_transfer_request_response.xml", XjcEpp.class),
+ Arguments.of("contact_transfer_request.xml", XjcEpp.class),
+ Arguments.of("contact_update.xml", XjcEpp.class),
+ Arguments.of("domain_check_response.xml", XjcEpp.class),
+ Arguments.of("domain_check.xml", XjcEpp.class),
+ Arguments.of("domain_create_response_offline_review_completed.xml", XjcEpp.class),
+ Arguments.of("domain_create_response_offline_review.xml", XjcEpp.class),
+ Arguments.of("domain_create_response.xml", XjcEpp.class),
+ Arguments.of("domain_create.xml", XjcEpp.class),
+ Arguments.of("domain_delete.xml", XjcEpp.class),
+ Arguments.of("domain_info_response_addperiod.xml", XjcEpp.class),
+ Arguments.of("domain_info_response_pendingdelete.xml", XjcEpp.class),
+ Arguments.of("domain_info_response_pendingrestore.xml", XjcEpp.class),
+ Arguments.of("domain_info_response_redemptionperiod.xml", XjcEpp.class),
+ Arguments.of("domain_info_response_unauthorized.xml", XjcEpp.class),
+ Arguments.of("domain_info_response.xml", XjcEpp.class),
+ Arguments.of("domain_info_with_auth.xml", XjcEpp.class),
+ Arguments.of("domain_info.xml", XjcEpp.class),
+ Arguments.of("domain_renew_response.xml", XjcEpp.class),
+ Arguments.of("domain_renew.xml", XjcEpp.class),
+ Arguments.of("domain_transfer_query_response.xml", XjcEpp.class),
+ Arguments.of("domain_transfer_query.xml", XjcEpp.class),
+ Arguments.of("domain_transfer_request_response.xml", XjcEpp.class),
+ Arguments.of("domain_transfer_request.xml", XjcEpp.class),
+ Arguments.of("domain_update_restore_report.xml", XjcEpp.class),
+ Arguments.of("domain_update_restore_request.xml", XjcEpp.class),
+ Arguments.of("domain_update.xml", XjcEpp.class),
+ Arguments.of("generic_success_response.xml", XjcEpp.class),
+ Arguments.of("greeting.xml", XjcEpp.class),
+ Arguments.of("host_check_response.xml", XjcEpp.class),
+ Arguments.of("host_check.xml", XjcEpp.class),
+ Arguments.of("host_create_response_offline_review_complete.xml", XjcEpp.class),
+ Arguments.of("host_create_response_offline_review.xml", XjcEpp.class),
+ Arguments.of("host_create_response.xml", XjcEpp.class),
+ Arguments.of("host_create.xml", XjcEpp.class),
+ Arguments.of("host_delete_response.xml", XjcEpp.class),
+ Arguments.of("host_delete.xml", XjcEpp.class),
+ Arguments.of("host_info_response.xml", XjcEpp.class),
+ Arguments.of("host_info.xml", XjcEpp.class),
+ Arguments.of("host_update.xml", XjcEpp.class),
+ Arguments.of("login.xml", XjcEpp.class),
+ Arguments.of("logout_response.xml", XjcEpp.class),
+ Arguments.of("logout.xml", XjcEpp.class),
+ Arguments.of("poll_ack_response.xml", XjcEpp.class),
+ Arguments.of("poll_ack.xml", XjcEpp.class),
+ Arguments.of("poll_response_empty.xml", XjcEpp.class),
+ Arguments.of("poll_response_mixed.xml", XjcEpp.class),
+ Arguments.of("poll.xml", XjcEpp.class),
+ Arguments.of("rde_deposit_differential.xml", XjcRdeDeposit.class),
+ Arguments.of("rde_deposit_full.xml", XjcRdeDeposit.class),
+ Arguments.of("restore_request_response.xml", XjcEpp.class));
}
- @DataPoints
- public static final Good[] GOOD = new Good[] {
- new Good("contact_check_response.xml", XjcEpp.class),
- new Good("contact_check.xml", XjcEpp.class),
- new Good("contact_create_response_offline_review_completed.xml", XjcEpp.class),
- new Good("contact_create_response_offline_review.xml", XjcEpp.class),
- new Good("contact_create_response.xml", XjcEpp.class),
- new Good("contact_create.xml", XjcEpp.class),
- new Good("contact_delete_response.xml", XjcEpp.class),
- new Good("contact_delete.xml", XjcEpp.class),
- new Good("contact_info_response.xml", XjcEpp.class),
- new Good("contact_info.xml", XjcEpp.class),
- new Good("contact_transfer_query_response.xml", XjcEpp.class),
- new Good("contact_transfer_query.xml", XjcEpp.class),
- new Good("contact_transfer_request_response.xml", XjcEpp.class),
- new Good("contact_transfer_request.xml", XjcEpp.class),
- new Good("contact_update.xml", XjcEpp.class),
- new Good("domain_check_response.xml", XjcEpp.class),
- new Good("domain_check.xml", XjcEpp.class),
- new Good("domain_create_response_offline_review_completed.xml", XjcEpp.class),
- new Good("domain_create_response_offline_review.xml", XjcEpp.class),
- new Good("domain_create_response.xml", XjcEpp.class),
- new Good("domain_create.xml", XjcEpp.class),
- new Good("domain_delete.xml", XjcEpp.class),
- new Good("domain_info_response_addperiod.xml", XjcEpp.class),
- new Good("domain_info_response_pendingdelete.xml", XjcEpp.class),
- new Good("domain_info_response_pendingrestore.xml", XjcEpp.class),
- new Good("domain_info_response_redemptionperiod.xml", XjcEpp.class),
- new Good("domain_info_response_unauthorized.xml", XjcEpp.class),
- new Good("domain_info_response.xml", XjcEpp.class),
- new Good("domain_info_with_auth.xml", XjcEpp.class),
- new Good("domain_info.xml", XjcEpp.class),
- new Good("domain_renew_response.xml", XjcEpp.class),
- new Good("domain_renew.xml", XjcEpp.class),
- new Good("domain_transfer_query_response.xml", XjcEpp.class),
- new Good("domain_transfer_query.xml", XjcEpp.class),
- new Good("domain_transfer_request_response.xml", XjcEpp.class),
- new Good("domain_transfer_request.xml", XjcEpp.class),
- new Good("domain_update_restore_report.xml", XjcEpp.class),
- new Good("domain_update_restore_request.xml", XjcEpp.class),
- new Good("domain_update.xml", XjcEpp.class),
- new Good("generic_success_response.xml", XjcEpp.class),
- new Good("greeting.xml", XjcEpp.class),
- new Good("host_check_response.xml", XjcEpp.class),
- new Good("host_check.xml", XjcEpp.class),
- new Good("host_create_response_offline_review_complete.xml", XjcEpp.class),
- new Good("host_create_response_offline_review.xml", XjcEpp.class),
- new Good("host_create_response.xml", XjcEpp.class),
- new Good("host_create.xml", XjcEpp.class),
- new Good("host_delete_response.xml", XjcEpp.class),
- new Good("host_delete.xml", XjcEpp.class),
- new Good("host_info_response.xml", XjcEpp.class),
- new Good("host_info.xml", XjcEpp.class),
- new Good("host_update.xml", XjcEpp.class),
- new Good("login.xml", XjcEpp.class),
- new Good("logout_response.xml", XjcEpp.class),
- new Good("logout.xml", XjcEpp.class),
- new Good("poll_ack_response.xml", XjcEpp.class),
- new Good("poll_ack.xml", XjcEpp.class),
- new Good("poll_response_empty.xml", XjcEpp.class),
- new Good("poll_response_mixed.xml", XjcEpp.class),
- new Good("poll.xml", XjcEpp.class),
- new Good("rde_deposit_differential.xml", XjcRdeDeposit.class),
- new Good("rde_deposit_full.xml", XjcRdeDeposit.class),
- new Good("restore_request_response.xml", XjcEpp.class),
- };
-
- @DataPoints
- public static final Evil[] EVIL = new Evil[] {
- new Evil("invalid_greeting.xml", "dcp}' is expected"),
- };
-
- @Theory
- public void testValid(Good v) throws Exception {
- XjcObject xml = unmarshal(XjcObject.class, v.xmlStream);
- assertThat(xml).isInstanceOf(v.clazz);
- }
-
- @Theory
- public void testInvalid(Evil v) {
- Throwable thrown = assertThrows(Throwable.class, () -> unmarshal(XjcObject.class, v.xmlStream));
- assertThat(thrown).hasMessageThat().contains(v.error);
+ private static ByteArrayInputStream loadAsStream(String filename) {
+ return new ByteArrayInputStream(loadFile(XmlTestdataTest.class, filename).getBytes(UTF_8));
}
}
diff --git a/core/src/test/java/google/registry/xml/DateAdapterTest.java b/core/src/test/java/google/registry/xml/DateAdapterTest.java
index 74704bdb9..e99ebf250 100644
--- a/core/src/test/java/google/registry/xml/DateAdapterTest.java
+++ b/core/src/test/java/google/registry/xml/DateAdapterTest.java
@@ -15,7 +15,7 @@
package google.registry.xml;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.joda.time.LocalDate;
import org.junit.jupiter.api.Test;
diff --git a/core/src/test/java/google/registry/xml/UtcDateTimeAdapterTest.java b/core/src/test/java/google/registry/xml/UtcDateTimeAdapterTest.java
index 3b89ff779..9083916a5 100644
--- a/core/src/test/java/google/registry/xml/UtcDateTimeAdapterTest.java
+++ b/core/src/test/java/google/registry/xml/UtcDateTimeAdapterTest.java
@@ -16,7 +16,7 @@ package google.registry.xml;
import static com.google.common.truth.Truth.assertThat;
import static org.joda.time.DateTimeZone.UTC;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.joda.time.DateTime;
import org.joda.time.DateTimeZone;
diff --git a/core/src/test/java/google/registry/xml/XmlTestUtilsTest.java b/core/src/test/java/google/registry/xml/XmlTestUtilsTest.java
index 8e91151d7..8142c8477 100644
--- a/core/src/test/java/google/registry/xml/XmlTestUtilsTest.java
+++ b/core/src/test/java/google/registry/xml/XmlTestUtilsTest.java
@@ -16,7 +16,7 @@ package google.registry.xml;
import static google.registry.testing.TestDataHelper.loadFile;
import static google.registry.xml.XmlTestUtils.assertXmlEquals;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import org.junit.jupiter.api.Test;
diff --git a/db/build.gradle b/db/build.gradle
index f9d7b3e82..aef61925f 100644
--- a/db/build.gradle
+++ b/db/build.gradle
@@ -12,8 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-import org.gradle.api.internal.tasks.userinput.UserInputHandler
-
plugins {
id "org.flywaydb.flyway" version "6.0.1"
id 'maven-publish'
@@ -159,12 +157,12 @@ dependencies {
testCompile deps['com.google.guava:guava']
testCompile deps['com.google.truth:truth']
testRuntime deps['io.github.java-diff-utils:java-diff-utils']
- testCompile deps['junit:junit']
testCompile deps['org.junit.jupiter:junit-jupiter-api']
testCompile deps['org.junit.jupiter:junit-jupiter-engine']
- testCompile deps['org.junit.vintage:junit-vintage-engine']
testCompile deps['org.testcontainers:postgresql']
testCompile deps['org.testcontainers:testcontainers']
+ testCompile deps['org.testcontainers:junit-jupiter']
+ testCompile deps['org.testcontainers:postgresql']
testCompile project(path: ':common', configuration: 'testing')
}
diff --git a/db/gradle/dependency-locks/testCompile.lockfile b/db/gradle/dependency-locks/testCompile.lockfile
index 88037eb24..bbb1f70f1 100644
--- a/db/gradle/dependency-locks/testCompile.lockfile
+++ b/db/gradle/dependency-locks/testCompile.lockfile
@@ -13,7 +13,7 @@ com.google.truth:truth:1.0
com.googlecode.java-diff-utils:diffutils:1.3.0
com.kohlschutter.junixsocket:junixsocket-common:2.0.4
com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
-junit:junit:4.13
+junit:junit:4.12
net.java.dev.jna:jna-platform:5.5.0
net.java.dev.jna:jna:5.5.0
org.apache.commons:commons-compress:1.20
@@ -27,7 +27,6 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.rnorth.duct-tape:duct-tape:1.0.8
@@ -37,5 +36,6 @@ org.scijava:native-lib-loader:2.0.2
org.slf4j:slf4j-api:1.7.30
org.testcontainers:database-commons:1.14.3
org.testcontainers:jdbc:1.14.3
+org.testcontainers:junit-jupiter:1.14.3
org.testcontainers:postgresql:1.14.3
org.testcontainers:testcontainers:1.14.3
diff --git a/db/gradle/dependency-locks/testCompileClasspath.lockfile b/db/gradle/dependency-locks/testCompileClasspath.lockfile
index 88037eb24..bbb1f70f1 100644
--- a/db/gradle/dependency-locks/testCompileClasspath.lockfile
+++ b/db/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -13,7 +13,7 @@ com.google.truth:truth:1.0
com.googlecode.java-diff-utils:diffutils:1.3.0
com.kohlschutter.junixsocket:junixsocket-common:2.0.4
com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
-junit:junit:4.13
+junit:junit:4.12
net.java.dev.jna:jna-platform:5.5.0
net.java.dev.jna:jna:5.5.0
org.apache.commons:commons-compress:1.20
@@ -27,7 +27,6 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.rnorth.duct-tape:duct-tape:1.0.8
@@ -37,5 +36,6 @@ org.scijava:native-lib-loader:2.0.2
org.slf4j:slf4j-api:1.7.30
org.testcontainers:database-commons:1.14.3
org.testcontainers:jdbc:1.14.3
+org.testcontainers:junit-jupiter:1.14.3
org.testcontainers:postgresql:1.14.3
org.testcontainers:testcontainers:1.14.3
diff --git a/db/gradle/dependency-locks/testRuntime.lockfile b/db/gradle/dependency-locks/testRuntime.lockfile
index 8714da385..214c81662 100644
--- a/db/gradle/dependency-locks/testRuntime.lockfile
+++ b/db/gradle/dependency-locks/testRuntime.lockfile
@@ -15,7 +15,7 @@ com.googlecode.java-diff-utils:diffutils:1.3.0
com.kohlschutter.junixsocket:junixsocket-common:2.0.4
com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
io.github.java-diff-utils:java-diff-utils:4.0
-junit:junit:4.13
+junit:junit:4.12
net.java.dev.jna:jna-platform:5.5.0
net.java.dev.jna:jna:5.5.0
org.apache.commons:commons-compress:1.20
@@ -30,7 +30,6 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.rnorth.duct-tape:duct-tape:1.0.8
@@ -40,5 +39,6 @@ org.scijava:native-lib-loader:2.0.2
org.slf4j:slf4j-api:1.7.30
org.testcontainers:database-commons:1.14.3
org.testcontainers:jdbc:1.14.3
+org.testcontainers:junit-jupiter:1.14.3
org.testcontainers:postgresql:1.14.3
org.testcontainers:testcontainers:1.14.3
diff --git a/db/gradle/dependency-locks/testRuntimeClasspath.lockfile b/db/gradle/dependency-locks/testRuntimeClasspath.lockfile
index 645ac30ff..ff082d1da 100644
--- a/db/gradle/dependency-locks/testRuntimeClasspath.lockfile
+++ b/db/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -38,7 +38,7 @@ io.github.java-diff-utils:java-diff-utils:4.0
io.grpc:grpc-context:1.22.1
io.opencensus:opencensus-api:0.24.0
io.opencensus:opencensus-contrib-http-util:0.24.0
-junit:junit:4.13
+junit:junit:4.12
net.java.dev.jna:jna-platform:5.5.0
net.java.dev.jna:jna:5.5.0
org.apache.commons:commons-compress:1.20
@@ -55,7 +55,6 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.ow2.asm:asm-analysis:8.0.1
@@ -71,5 +70,6 @@ org.scijava:native-lib-loader:2.0.2
org.slf4j:slf4j-api:1.7.30
org.testcontainers:database-commons:1.14.3
org.testcontainers:jdbc:1.14.3
+org.testcontainers:junit-jupiter:1.14.3
org.testcontainers:postgresql:1.14.3
org.testcontainers:testcontainers:1.14.3
diff --git a/db/src/test/java/google/registry/sql/flyway/SchemaTest.java b/db/src/test/java/google/registry/sql/flyway/SchemaTest.java
index 1315c0ef6..00580dbb8 100644
--- a/db/src/test/java/google/registry/sql/flyway/SchemaTest.java
+++ b/db/src/test/java/google/registry/sql/flyway/SchemaTest.java
@@ -25,17 +25,16 @@ import java.net.URL;
import java.nio.charset.StandardCharsets;
import java.nio.file.Paths;
import org.flywaydb.core.Flyway;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
import org.testcontainers.containers.BindMode;
-import org.testcontainers.containers.Container;
+import org.testcontainers.containers.Container.ExecResult;
import org.testcontainers.containers.PostgreSQLContainer;
+import org.testcontainers.junit.jupiter.Container;
+import org.testcontainers.junit.jupiter.Testcontainers;
/** Unit tests about Cloud SQL schema. */
-@RunWith(JUnit4.class)
-public class SchemaTest {
+@Testcontainers
+class SchemaTest {
// Resource path that is mapped to the testcontainer instance.
private static final String MOUNTED_RESOURCE_PATH = "testcontainer/mount";
@@ -51,14 +50,14 @@ public class SchemaTest {
* schema generated by the 'pg_dump' command. Compared with communicating over stdout, it is
* easier to update the golden schema this way.
*/
- @Rule
- public PostgreSQLContainer sqlContainer =
+ @Container
+ private PostgreSQLContainer sqlContainer =
new PostgreSQLContainer<>(NomulusPostgreSql.getDockerTag())
.withClasspathResourceMapping(
MOUNTED_RESOURCE_PATH, CONTAINER_MOUNT_POINT, BindMode.READ_WRITE);
@Test
- public void deploySchema_success() throws Exception {
+ void deploySchema_success() throws Exception {
Flyway flyway =
Flyway.configure()
.locations("sql/flyway")
@@ -71,7 +70,7 @@ public class SchemaTest {
assertThat(flyway.migrate()).isGreaterThan(0);
flyway.validate();
- Container.ExecResult execResult =
+ ExecResult execResult =
sqlContainer.execInContainer(
StandardCharsets.UTF_8,
getSchemaDumpCommand(sqlContainer.getUsername(), sqlContainer.getDatabaseName()));
diff --git a/docs/gradle/dependency-locks/annotationProcessor.lockfile b/docs/gradle/dependency-locks/annotationProcessor.lockfile
new file mode 100644
index 000000000..0e2d9b8d4
--- /dev/null
+++ b/docs/gradle/dependency-locks/annotationProcessor.lockfile
@@ -0,0 +1,24 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+com.github.kevinstern:software-and-algorithms:1.0
+com.github.stephenc.jcip:jcip-annotations:1.0-1
+com.google.auto:auto-common:0.10
+com.google.code.findbugs:jFormatString:3.0.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.errorprone:error_prone_annotation:2.3.3
+com.google.errorprone:error_prone_annotations:2.3.3
+com.google.errorprone:error_prone_check_api:2.3.3
+com.google.errorprone:error_prone_core:2.3.3
+com.google.errorprone:error_prone_type_annotations:2.3.3
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:27.0.1-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.j2objc:j2objc-annotations:1.1
+com.google.protobuf:protobuf-java:3.4.0
+com.googlecode.java-diff-utils:diffutils:1.3.0
+org.checkerframework:checker-qual:2.5.3
+org.checkerframework:dataflow:2.5.3
+org.checkerframework:javacutil:2.5.3
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.pcollections:pcollections:2.1.2
diff --git a/docs/gradle/dependency-locks/apt.lockfile b/docs/gradle/dependency-locks/apt.lockfile
new file mode 100644
index 000000000..656c5dbcc
--- /dev/null
+++ b/docs/gradle/dependency-locks/apt.lockfile
@@ -0,0 +1,3 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
diff --git a/docs/gradle/dependency-locks/archives.lockfile b/docs/gradle/dependency-locks/archives.lockfile
new file mode 100644
index 000000000..656c5dbcc
--- /dev/null
+++ b/docs/gradle/dependency-locks/archives.lockfile
@@ -0,0 +1,3 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
diff --git a/docs/gradle/dependency-locks/buildscript-classpath.lockfile b/docs/gradle/dependency-locks/buildscript-classpath.lockfile
new file mode 100644
index 000000000..656c5dbcc
--- /dev/null
+++ b/docs/gradle/dependency-locks/buildscript-classpath.lockfile
@@ -0,0 +1,3 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
diff --git a/docs/gradle/dependency-locks/checkstyle.lockfile b/docs/gradle/dependency-locks/checkstyle.lockfile
new file mode 100644
index 000000000..1f09ae516
--- /dev/null
+++ b/docs/gradle/dependency-locks/checkstyle.lockfile
@@ -0,0 +1,18 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+antlr:antlr:2.7.7
+com.google.code.findbugs:jsr305:3.0.2
+com.google.errorprone:error_prone_annotations:2.3.2
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:28.1-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.j2objc:j2objc-annotations:1.3
+com.puppycrawl.tools:checkstyle:8.27
+commons-beanutils:commons-beanutils:1.9.4
+commons-collections:commons-collections:3.2.2
+info.picocli:picocli:4.1.1
+net.sf.saxon:Saxon-HE:9.9.1-5
+org.antlr:antlr4-runtime:4.7.2
+org.checkerframework:checker-qual:2.8.1
+org.codehaus.mojo:animal-sniffer-annotations:1.18
diff --git a/docs/gradle/dependency-locks/compile.lockfile b/docs/gradle/dependency-locks/compile.lockfile
new file mode 100644
index 000000000..191b19c5a
--- /dev/null
+++ b/docs/gradle/dependency-locks/compile.lockfile
@@ -0,0 +1,249 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/compileClasspath.lockfile b/docs/gradle/dependency-locks/compileClasspath.lockfile
new file mode 100644
index 000000000..5532f5f43
--- /dev/null
+++ b/docs/gradle/dependency-locks/compileClasspath.lockfile
@@ -0,0 +1,243 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.jvnet.staxex:stax-ex:1.8
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/compileOnly.lockfile b/docs/gradle/dependency-locks/compileOnly.lockfile
new file mode 100644
index 000000000..656c5dbcc
--- /dev/null
+++ b/docs/gradle/dependency-locks/compileOnly.lockfile
@@ -0,0 +1,3 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
diff --git a/docs/gradle/dependency-locks/default.lockfile b/docs/gradle/dependency-locks/default.lockfile
new file mode 100644
index 000000000..191b19c5a
--- /dev/null
+++ b/docs/gradle/dependency-locks/default.lockfile
@@ -0,0 +1,249 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/deploy_jar.lockfile b/docs/gradle/dependency-locks/deploy_jar.lockfile
new file mode 100644
index 000000000..47c2875d9
--- /dev/null
+++ b/docs/gradle/dependency-locks/deploy_jar.lockfile
@@ -0,0 +1,246 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.jvnet.staxex:stax-ex:1.8
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/errorprone.lockfile b/docs/gradle/dependency-locks/errorprone.lockfile
new file mode 100644
index 000000000..0e2d9b8d4
--- /dev/null
+++ b/docs/gradle/dependency-locks/errorprone.lockfile
@@ -0,0 +1,24 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+com.github.kevinstern:software-and-algorithms:1.0
+com.github.stephenc.jcip:jcip-annotations:1.0-1
+com.google.auto:auto-common:0.10
+com.google.code.findbugs:jFormatString:3.0.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.errorprone:error_prone_annotation:2.3.3
+com.google.errorprone:error_prone_annotations:2.3.3
+com.google.errorprone:error_prone_check_api:2.3.3
+com.google.errorprone:error_prone_core:2.3.3
+com.google.errorprone:error_prone_type_annotations:2.3.3
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:27.0.1-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.j2objc:j2objc-annotations:1.1
+com.google.protobuf:protobuf-java:3.4.0
+com.googlecode.java-diff-utils:diffutils:1.3.0
+org.checkerframework:checker-qual:2.5.3
+org.checkerframework:dataflow:2.5.3
+org.checkerframework:javacutil:2.5.3
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.pcollections:pcollections:2.1.2
diff --git a/docs/gradle/dependency-locks/errorproneJavac.lockfile b/docs/gradle/dependency-locks/errorproneJavac.lockfile
new file mode 100644
index 000000000..43f098f5c
--- /dev/null
+++ b/docs/gradle/dependency-locks/errorproneJavac.lockfile
@@ -0,0 +1,4 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+com.google.errorprone:javac:9+181-r4173-1
diff --git a/docs/gradle/dependency-locks/jacocoAgent.lockfile b/docs/gradle/dependency-locks/jacocoAgent.lockfile
new file mode 100644
index 000000000..6b7fa31b5
--- /dev/null
+++ b/docs/gradle/dependency-locks/jacocoAgent.lockfile
@@ -0,0 +1,4 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+org.jacoco:org.jacoco.agent:0.8.5
diff --git a/docs/gradle/dependency-locks/jacocoAnt.lockfile b/docs/gradle/dependency-locks/jacocoAnt.lockfile
new file mode 100644
index 000000000..40e2c298b
--- /dev/null
+++ b/docs/gradle/dependency-locks/jacocoAnt.lockfile
@@ -0,0 +1,11 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+org.jacoco:org.jacoco.agent:0.8.5
+org.jacoco:org.jacoco.ant:0.8.5
+org.jacoco:org.jacoco.core:0.8.5
+org.jacoco:org.jacoco.report:0.8.5
+org.ow2.asm:asm-analysis:7.2
+org.ow2.asm:asm-commons:7.2
+org.ow2.asm:asm-tree:7.2
+org.ow2.asm:asm:7.2
diff --git a/docs/gradle/dependency-locks/runtime.lockfile b/docs/gradle/dependency-locks/runtime.lockfile
new file mode 100644
index 000000000..191b19c5a
--- /dev/null
+++ b/docs/gradle/dependency-locks/runtime.lockfile
@@ -0,0 +1,249 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/runtimeClasspath.lockfile b/docs/gradle/dependency-locks/runtimeClasspath.lockfile
new file mode 100644
index 000000000..47c2875d9
--- /dev/null
+++ b/docs/gradle/dependency-locks/runtimeClasspath.lockfile
@@ -0,0 +1,246 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.jvnet.staxex:stax-ex:1.8
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/testAnnotationProcessor.lockfile b/docs/gradle/dependency-locks/testAnnotationProcessor.lockfile
new file mode 100644
index 000000000..0e2d9b8d4
--- /dev/null
+++ b/docs/gradle/dependency-locks/testAnnotationProcessor.lockfile
@@ -0,0 +1,24 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+com.github.kevinstern:software-and-algorithms:1.0
+com.github.stephenc.jcip:jcip-annotations:1.0-1
+com.google.auto:auto-common:0.10
+com.google.code.findbugs:jFormatString:3.0.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.errorprone:error_prone_annotation:2.3.3
+com.google.errorprone:error_prone_annotations:2.3.3
+com.google.errorprone:error_prone_check_api:2.3.3
+com.google.errorprone:error_prone_core:2.3.3
+com.google.errorprone:error_prone_type_annotations:2.3.3
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:27.0.1-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.j2objc:j2objc-annotations:1.1
+com.google.protobuf:protobuf-java:3.4.0
+com.googlecode.java-diff-utils:diffutils:1.3.0
+org.checkerframework:checker-qual:2.5.3
+org.checkerframework:dataflow:2.5.3
+org.checkerframework:javacutil:2.5.3
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.pcollections:pcollections:2.1.2
diff --git a/docs/gradle/dependency-locks/testApt.lockfile b/docs/gradle/dependency-locks/testApt.lockfile
new file mode 100644
index 000000000..656c5dbcc
--- /dev/null
+++ b/docs/gradle/dependency-locks/testApt.lockfile
@@ -0,0 +1,3 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
diff --git a/docs/gradle/dependency-locks/testCompile.lockfile b/docs/gradle/dependency-locks/testCompile.lockfile
new file mode 100644
index 000000000..8bda33bfa
--- /dev/null
+++ b/docs/gradle/dependency-locks/testCompile.lockfile
@@ -0,0 +1,260 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.google.truth:truth:1.0
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.java-diff-utils:diffutils:1.3.0
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.thoughtworks.qdox:qdox:1.12.1
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.apiguardian:apiguardian-api:1.1.0
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-compat-qual:2.5.5
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.junit.jupiter:junit-jupiter-api:5.6.2
+org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.platform:junit-platform-commons:1.6.2
+org.junit.platform:junit-platform-engine:1.6.2
+org.junit:junit-bom:5.6.2
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.opentest4j:opentest4j:1.2.0
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/testCompileClasspath.lockfile b/docs/gradle/dependency-locks/testCompileClasspath.lockfile
new file mode 100644
index 000000000..f3fdc0b4d
--- /dev/null
+++ b/docs/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -0,0 +1,257 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.google.truth:truth:1.0
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.java-diff-utils:diffutils:1.3.0
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.thoughtworks.qdox:qdox:1.12.1
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.apiguardian:apiguardian-api:1.1.0
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-compat-qual:2.5.5
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.junit.jupiter:junit-jupiter-api:5.6.2
+org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.platform:junit-platform-commons:1.6.2
+org.junit.platform:junit-platform-engine:1.6.2
+org.junit:junit-bom:5.6.2
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.opentest4j:opentest4j:1.2.0
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/testCompileOnly.lockfile b/docs/gradle/dependency-locks/testCompileOnly.lockfile
new file mode 100644
index 000000000..656c5dbcc
--- /dev/null
+++ b/docs/gradle/dependency-locks/testCompileOnly.lockfile
@@ -0,0 +1,3 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
diff --git a/docs/gradle/dependency-locks/testRuntime.lockfile b/docs/gradle/dependency-locks/testRuntime.lockfile
new file mode 100644
index 000000000..8bda33bfa
--- /dev/null
+++ b/docs/gradle/dependency-locks/testRuntime.lockfile
@@ -0,0 +1,260 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.google.truth:truth:1.0
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.java-diff-utils:diffutils:1.3.0
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.thoughtworks.qdox:qdox:1.12.1
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.apiguardian:apiguardian-api:1.1.0
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-compat-qual:2.5.5
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.junit.jupiter:junit-jupiter-api:5.6.2
+org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.platform:junit-platform-commons:1.6.2
+org.junit.platform:junit-platform-engine:1.6.2
+org.junit:junit-bom:5.6.2
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.opentest4j:opentest4j:1.2.0
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/docs/gradle/dependency-locks/testRuntimeClasspath.lockfile b/docs/gradle/dependency-locks/testRuntimeClasspath.lockfile
new file mode 100644
index 000000000..8bda33bfa
--- /dev/null
+++ b/docs/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -0,0 +1,260 @@
+# This is a Gradle generated file for dependency locking.
+# Manual edits can break the build and are not advised.
+# This file is expected to be part of source control.
+androidx.annotation:annotation:1.1.0
+antlr:antlr:2.7.7
+aopalliance:aopalliance:1.0
+args4j:args4j:2.0.23
+cglib:cglib-nodep:2.2
+com.beust:jcommander:1.60
+com.fasterxml.jackson.core:jackson-annotations:2.9.10
+com.fasterxml.jackson.core:jackson-core:2.10.2
+com.fasterxml.jackson.core:jackson-databind:2.9.10
+com.fasterxml:classmate:1.5.1
+com.github.jnr:jffi:1.2.23
+com.github.jnr:jnr-a64asm:1.0.0
+com.github.jnr:jnr-constants:0.9.15
+com.github.jnr:jnr-enxio:0.26
+com.github.jnr:jnr-ffi:2.1.13
+com.github.jnr:jnr-posix:3.0.55
+com.github.jnr:jnr-unixsocket:0.30
+com.github.jnr:jnr-x86asm:1.0.2
+com.google.api-client:google-api-client-appengine:1.30.8
+com.google.api-client:google-api-client-jackson2:1.27.0
+com.google.api-client:google-api-client-java6:1.27.0
+com.google.api-client:google-api-client-servlet:1.30.8
+com.google.api-client:google-api-client:1.30.8
+com.google.api.grpc:grpc-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:grpc-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-bigtable-v2:0.38.0
+com.google.api.grpc:grpc-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:grpc-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:grpc-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-cloud-bigquerystorage-v1beta1:0.44.0
+com.google.api.grpc:proto-google-cloud-bigtable-admin-v2:0.38.0
+com.google.api.grpc:proto-google-cloud-bigtable-v2:0.44.0
+com.google.api.grpc:proto-google-cloud-datastore-v1:0.44.0
+com.google.api.grpc:proto-google-cloud-pubsub-v1:1.43.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-database-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-admin-instance-v1:1.6.0
+com.google.api.grpc:proto-google-cloud-spanner-v1:1.6.0
+com.google.api.grpc:proto-google-common-protos:1.12.0
+com.google.api.grpc:proto-google-iam-v1:0.12.0
+com.google.api:api-common:1.7.0
+com.google.api:gax-grpc:1.38.0
+com.google.api:gax-httpjson:0.52.0
+com.google.api:gax:1.38.0
+com.google.apis:google-api-services-admin-directory:directory_v1-rev72-1.22.0
+com.google.apis:google-api-services-appengine:v1-rev101-1.25.0
+com.google.apis:google-api-services-bigquery:v2-rev20181104-1.27.0
+com.google.apis:google-api-services-clouddebugger:v2-rev20180801-1.27.0
+com.google.apis:google-api-services-cloudkms:v1-rev12-1.22.0
+com.google.apis:google-api-services-cloudresourcemanager:v1-rev20181015-1.27.0
+com.google.apis:google-api-services-dataflow:v1b3-rev20190607-1.27.0
+com.google.apis:google-api-services-dns:v2beta1-rev6-1.22.0
+com.google.apis:google-api-services-drive:v2-rev160-1.19.1
+com.google.apis:google-api-services-groupssettings:v1-rev60-1.22.0
+com.google.apis:google-api-services-monitoring:v3-rev426-1.23.0
+com.google.apis:google-api-services-pubsub:v1-rev20181105-1.27.0
+com.google.apis:google-api-services-sheets:v4-rev483-1.22.0
+com.google.apis:google-api-services-sqladmin:v1beta4-rev20190827-1.30.1
+com.google.apis:google-api-services-storage:v1-rev20181109-1.27.0
+com.google.appengine.tools:appengine-gcs-client:0.6
+com.google.appengine.tools:appengine-mapreduce:0.9
+com.google.appengine.tools:appengine-pipeline:0.2.13
+com.google.appengine:appengine-api-1.0-sdk:1.9.48
+com.google.appengine:appengine-remote-api:1.9.48
+com.google.appengine:appengine-testing:1.9.58
+com.google.auth:google-auth-library-credentials:0.20.0
+com.google.auth:google-auth-library-oauth2-http:0.20.0
+com.google.auto.value:auto-value-annotations:1.7
+com.google.auto.value:auto-value:1.6.3
+com.google.cloud.bigdataoss:gcsio:1.9.16
+com.google.cloud.bigdataoss:util:1.9.16
+com.google.cloud.bigtable:bigtable-client-core:1.8.0
+com.google.cloud.datastore:datastore-v1-proto-client:1.6.0
+com.google.cloud.sql:jdbc-socket-factory-core:1.0.16
+com.google.cloud.sql:postgres-socket-factory:1.0.16
+com.google.cloud:google-cloud-bigquerystorage:0.79.0-alpha
+com.google.cloud:google-cloud-bigtable-admin:0.73.0-alpha
+com.google.cloud:google-cloud-bigtable:0.73.0-alpha
+com.google.cloud:google-cloud-core-grpc:1.61.0
+com.google.cloud:google-cloud-core-http:1.55.0
+com.google.cloud:google-cloud-core:1.61.0
+com.google.cloud:google-cloud-spanner:1.6.0
+com.google.code.findbugs:jsr305:3.0.2
+com.google.code.gson:gson:2.8.5
+com.google.common.html.types:types:1.0.4
+com.google.dagger:dagger:2.28
+com.google.errorprone:error_prone_annotations:2.3.4
+com.google.flogger:flogger-system-backend:0.3.1
+com.google.flogger:flogger:0.3.1
+com.google.flogger:google-extensions:0.3.1
+com.google.guava:failureaccess:1.0.1
+com.google.guava:guava:29.0-jre
+com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
+com.google.gwt:gwt-user:2.8.2
+com.google.http-client:google-http-client-appengine:1.34.1
+com.google.http-client:google-http-client-jackson2:1.34.1
+com.google.http-client:google-http-client-jackson:1.20.0
+com.google.http-client:google-http-client-protobuf:1.20.0
+com.google.http-client:google-http-client:1.34.1
+com.google.inject.extensions:guice-multibindings:4.1.0
+com.google.inject:guice:4.1.0
+com.google.j2objc:j2objc-annotations:1.3
+com.google.jsinterop:jsinterop-annotations:1.0.2
+com.google.monitoring-client:metrics:1.0.7
+com.google.monitoring-client:stackdriver:1.0.7
+com.google.oauth-client:google-oauth-client-appengine:1.30.5
+com.google.oauth-client:google-oauth-client-java6:1.28.0
+com.google.oauth-client:google-oauth-client-jetty:1.28.0
+com.google.oauth-client:google-oauth-client-servlet:1.30.5
+com.google.oauth-client:google-oauth-client:1.30.5
+com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-5
+com.google.protobuf:protobuf-java-util:3.6.1
+com.google.protobuf:protobuf-java:3.6.1
+com.google.re2j:re2j:1.1
+com.google.template:soy:2018-03-14
+com.google.truth:truth:1.0
+com.googlecode.charts4j:charts4j:1.3
+com.googlecode.java-diff-utils:diffutils:1.3.0
+com.googlecode.json-simple:json-simple:1.1.1
+com.ibm.icu:icu4j:57.1
+com.jcraft:jsch:0.1.55
+com.kohlschutter.junixsocket:junixsocket-common:2.0.4
+com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
+com.squareup.okhttp:okhttp:2.5.0
+com.squareup.okio:okio:1.13.0
+com.sun.istack:istack-commons-runtime:3.0.7
+com.sun.xml.fastinfoset:FastInfoset:1.2.15
+com.thoughtworks.paranamer:paranamer:2.7
+com.thoughtworks.qdox:qdox:1.12.1
+com.zaxxer:HikariCP:3.2.0
+commons-codec:commons-codec:1.11
+commons-logging:commons-logging:1.2
+dnsjava:dnsjava:2.1.7
+io.dropwizard.metrics:metrics-core:3.1.2
+io.grpc:grpc-all:1.17.1
+io.grpc:grpc-alts:1.17.1
+io.grpc:grpc-auth:1.17.1
+io.grpc:grpc-context:1.22.1
+io.grpc:grpc-core:1.17.1
+io.grpc:grpc-grpclb:1.17.1
+io.grpc:grpc-netty-shaded:1.17.1
+io.grpc:grpc-netty:1.17.1
+io.grpc:grpc-okhttp:1.17.1
+io.grpc:grpc-protobuf-lite:1.17.1
+io.grpc:grpc-protobuf-nano:1.17.1
+io.grpc:grpc-protobuf:1.17.1
+io.grpc:grpc-stub:1.17.1
+io.grpc:grpc-testing:1.17.1
+io.netty:netty-buffer:4.1.30.Final
+io.netty:netty-codec-http2:4.1.30.Final
+io.netty:netty-codec-http:4.1.30.Final
+io.netty:netty-codec-socks:4.1.30.Final
+io.netty:netty-codec:4.1.30.Final
+io.netty:netty-common:4.1.30.Final
+io.netty:netty-handler-proxy:4.1.30.Final
+io.netty:netty-handler:4.1.30.Final
+io.netty:netty-resolver:4.1.30.Final
+io.netty:netty-tcnative-boringssl-static:2.0.17.Final
+io.netty:netty-transport:4.1.30.Final
+io.opencensus:opencensus-api:0.24.0
+io.opencensus:opencensus-contrib-grpc-metrics:0.17.0
+io.opencensus:opencensus-contrib-grpc-util:0.17.0
+io.opencensus:opencensus-contrib-http-util:0.24.0
+it.unimi.dsi:fastutil:6.5.16
+javax.activation:activation:1.1
+javax.activation:javax.activation-api:1.2.0
+javax.annotation:javax.annotation-api:1.2
+javax.annotation:jsr250-api:1.0
+javax.inject:javax.inject:1
+javax.jdo:jdo2-api:2.3-eb
+javax.mail:mail:1.4
+javax.persistence:javax.persistence-api:2.2
+javax.servlet:servlet-api:2.5
+javax.transaction:transaction-api:1.1
+javax.validation:validation-api:1.0.0.GA
+javax.xml.bind:jaxb-api:2.3.1
+jline:jline:1.0
+joda-time:joda-time:2.10.3
+junit:junit:4.12
+net.bytebuddy:byte-buddy:1.10.10
+net.java.dev.jna:jna-platform:5.5.0
+net.java.dev.jna:jna:5.5.0
+org.apache.avro:avro:1.8.2
+org.apache.beam:beam-model-job-management:2.16.0
+org.apache.beam:beam-model-pipeline:2.16.0
+org.apache.beam:beam-runners-core-construction-java:2.16.0
+org.apache.beam:beam-runners-google-cloud-dataflow-java:2.16.0
+org.apache.beam:beam-sdks-java-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-google-cloud-platform-core:2.16.0
+org.apache.beam:beam-sdks-java-extensions-protobuf:2.16.0
+org.apache.beam:beam-sdks-java-io-google-cloud-platform:2.16.0
+org.apache.beam:beam-vendor-bytebuddy-1_9_3:0.1
+org.apache.beam:beam-vendor-grpc-1_21_0:0.1
+org.apache.beam:beam-vendor-guava-26_0-jre:0.1
+org.apache.commons:commons-compress:1.20
+org.apache.commons:commons-lang3:3.5
+org.apache.httpcomponents:httpclient:4.5.11
+org.apache.httpcomponents:httpcore:4.4.13
+org.apiguardian:apiguardian-api:1.1.0
+org.bouncycastle:bcpg-jdk15on:1.61
+org.bouncycastle:bcprov-jdk15on:1.61
+org.checkerframework:checker-compat-qual:2.5.5
+org.checkerframework:checker-qual:2.11.1
+org.codehaus.jackson:jackson-core-asl:1.9.13
+org.codehaus.jackson:jackson-mapper-asl:1.9.13
+org.codehaus.mojo:animal-sniffer-annotations:1.17
+org.dom4j:dom4j:2.1.3
+org.easymock:easymock:3.0
+org.flywaydb:flyway-core:5.2.4
+org.glassfish.jaxb:jaxb-runtime:2.3.1
+org.glassfish.jaxb:txw2:2.3.1
+org.hamcrest:hamcrest-core:1.3
+org.hibernate.common:hibernate-commons-annotations:5.1.0.Final
+org.hibernate:hibernate-core:5.4.17.Final
+org.hibernate:hibernate-hikaricp:5.4.17.Final
+org.javassist:javassist:3.24.0-GA
+org.jboss.logging:jboss-logging:3.3.2.Final
+org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.1.1.Final
+org.jboss:jandex:2.1.3.Final
+org.jetbrains:annotations:19.0.0
+org.joda:joda-money:1.0.1
+org.json:json:20160810
+org.junit.jupiter:junit-jupiter-api:5.6.2
+org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.platform:junit-platform-commons:1.6.2
+org.junit.platform:junit-platform-engine:1.6.2
+org.junit:junit-bom:5.6.2
+org.jvnet.staxex:stax-ex:1.8
+org.mockito:mockito-core:1.9.5
+org.mortbay.jetty:jetty-util:6.1.26
+org.mortbay.jetty:jetty:6.1.26
+org.objenesis:objenesis:1.2
+org.opentest4j:opentest4j:1.2.0
+org.ow2.asm:asm-analysis:8.0.1
+org.ow2.asm:asm-commons:7.1
+org.ow2.asm:asm-tree:8.0.1
+org.ow2.asm:asm-util:8.0.1
+org.ow2.asm:asm:8.0.1
+org.postgresql:postgresql:42.2.14
+org.rnorth.duct-tape:duct-tape:1.0.8
+org.rnorth.visible-assertions:visible-assertions:2.1.2
+org.rnorth:tcp-unix-socket-proxy:1.0.2
+org.scijava:native-lib-loader:2.0.2
+org.slf4j:slf4j-api:1.7.30
+org.slf4j:slf4j-jdk14:1.7.28
+org.testcontainers:database-commons:1.14.3
+org.testcontainers:jdbc:1.14.3
+org.testcontainers:postgresql:1.14.3
+org.testcontainers:testcontainers:1.14.3
+org.threeten:threetenbp:1.3.3
+org.tukaani:xz:1.8
+org.w3c.css:sac:1.3
+org.xerial.snappy:snappy-java:1.1.4
+org.yaml:snakeyaml:1.17
+xerces:xmlParserAPIs:2.6.2
+xpp3:xpp3:1.1.4c
diff --git a/networking/build.gradle b/networking/build.gradle
index 1385caf04..6ff57e163 100644
--- a/networking/build.gradle
+++ b/networking/build.gradle
@@ -33,10 +33,9 @@ dependencies {
runtime deps['io.netty:netty-tcnative-boringssl-static']
testCompile deps['com.google.truth:truth']
- testCompile deps['junit:junit']
testCompile deps['org.junit.jupiter:junit-jupiter-api']
testCompile deps['org.junit.jupiter:junit-jupiter-engine']
- testCompile deps['org.junit.vintage:junit-vintage-engine']
+ testCompile deps['org.junit.jupiter:junit-jupiter-params']
testCompile deps['org.bouncycastle:bcpkix-jdk15on']
testCompile deps['org.bouncycastle:bcprov-jdk15on']
diff --git a/networking/gradle/dependency-locks/testCompile.lockfile b/networking/gradle/dependency-locks/testCompile.lockfile
index 210494a6d..de781f0f9 100644
--- a/networking/gradle/dependency-locks/testCompile.lockfile
+++ b/networking/gradle/dependency-locks/testCompile.lockfile
@@ -42,7 +42,7 @@ javax.inject:javax.inject:1
javax.mail:mail:1.4
javax.xml.bind:jaxb-api:2.3.0
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apache.httpcomponents:httpclient:4.5.11
org.apache.httpcomponents:httpcore:4.4.13
org.apiguardian:apiguardian-api:1.1.0
@@ -53,9 +53,9 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/networking/gradle/dependency-locks/testCompileClasspath.lockfile b/networking/gradle/dependency-locks/testCompileClasspath.lockfile
index 210494a6d..de781f0f9 100644
--- a/networking/gradle/dependency-locks/testCompileClasspath.lockfile
+++ b/networking/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -42,7 +42,7 @@ javax.inject:javax.inject:1
javax.mail:mail:1.4
javax.xml.bind:jaxb-api:2.3.0
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apache.httpcomponents:httpclient:4.5.11
org.apache.httpcomponents:httpcore:4.4.13
org.apiguardian:apiguardian-api:1.1.0
@@ -53,9 +53,9 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/networking/gradle/dependency-locks/testRuntime.lockfile b/networking/gradle/dependency-locks/testRuntime.lockfile
index 0f7c6cdd6..8a9eff323 100644
--- a/networking/gradle/dependency-locks/testRuntime.lockfile
+++ b/networking/gradle/dependency-locks/testRuntime.lockfile
@@ -44,7 +44,7 @@ javax.inject:javax.inject:1
javax.mail:mail:1.4
javax.xml.bind:jaxb-api:2.3.0
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apache.httpcomponents:httpclient:4.5.11
org.apache.httpcomponents:httpcore:4.4.13
org.apiguardian:apiguardian-api:1.1.0
@@ -55,9 +55,9 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/networking/gradle/dependency-locks/testRuntimeClasspath.lockfile b/networking/gradle/dependency-locks/testRuntimeClasspath.lockfile
index 0f7c6cdd6..8a9eff323 100644
--- a/networking/gradle/dependency-locks/testRuntimeClasspath.lockfile
+++ b/networking/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -44,7 +44,7 @@ javax.inject:javax.inject:1
javax.mail:mail:1.4
javax.xml.bind:jaxb-api:2.3.0
joda-time:joda-time:2.9.2
-junit:junit:4.13
+junit:junit:4.12
org.apache.httpcomponents:httpclient:4.5.11
org.apache.httpcomponents:httpcore:4.4.13
org.apiguardian:apiguardian-api:1.1.0
@@ -55,9 +55,9 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/networking/src/test/java/google/registry/networking/handler/NettyRule.java b/networking/src/test/java/google/registry/networking/handler/NettyExtension.java
similarity index 95%
rename from networking/src/test/java/google/registry/networking/handler/NettyRule.java
rename to networking/src/test/java/google/registry/networking/handler/NettyExtension.java
index 1896b1227..55a39a64a 100644
--- a/networking/src/test/java/google/registry/networking/handler/NettyRule.java
+++ b/networking/src/test/java/google/registry/networking/handler/NettyExtension.java
@@ -18,7 +18,7 @@ import static com.google.common.base.Preconditions.checkState;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.US_ASCII;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Throwables;
import com.google.common.truth.ThrowableSubject;
@@ -41,14 +41,15 @@ import io.netty.util.ReferenceCountUtil;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.Future;
-import org.junit.rules.ExternalResource;
+import org.junit.jupiter.api.extension.AfterEachCallback;
+import org.junit.jupiter.api.extension.ExtensionContext;
/**
- * Helper for setting up and testing client / server connection with netty.
+ * JUnit extension to set up and test the client / server connection with netty.
*
* Used in {@link SslClientInitializerTest} and {@link SslServerInitializerTest}.
*/
-public final class NettyRule extends ExternalResource {
+public final class NettyExtension implements AfterEachCallback {
// All I/O operations are done inside the single thread within this event loop group, which is
// different from the main test thread. Therefore synchronizations are required to make sure that
@@ -223,7 +224,7 @@ public final class NettyRule extends ExternalResource {
}
@Override
- protected void after() {
+ public void afterEach(ExtensionContext context) {
Future> unusedFuture = eventLoopGroup.shutdownGracefully();
}
diff --git a/networking/src/test/java/google/registry/networking/handler/SslClientInitializerTest.java b/networking/src/test/java/google/registry/networking/handler/SslClientInitializerTest.java
index 915f6b39d..603d53608 100644
--- a/networking/src/test/java/google/registry/networking/handler/SslClientInitializerTest.java
+++ b/networking/src/test/java/google/registry/networking/handler/SslClientInitializerTest.java
@@ -47,14 +47,13 @@ import java.time.Duration;
import java.time.Instant;
import java.util.Date;
import java.util.function.Function;
+import java.util.stream.Stream;
import javax.net.ssl.SSLException;
import javax.net.ssl.SSLSession;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
-import org.junit.runners.Parameterized.Parameter;
-import org.junit.runners.Parameterized.Parameters;
+import org.junit.jupiter.api.extension.RegisterExtension;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.Arguments;
+import org.junit.jupiter.params.provider.MethodSource;
/**
* Unit tests for {@link SslClientInitializer}.
@@ -67,8 +66,7 @@ import org.junit.runners.Parameterized.Parameters;
*
The local addresses used in each test method must to be different, otherwise tests run in
* parallel may interfere with each other.
*/
-@RunWith(Parameterized.class)
-public class SslClientInitializerTest {
+class SslClientInitializerTest {
/** Fake host to test if the SSL engine gets the correct peer host. */
private static final String SSL_HOST = "www.example.tld";
@@ -80,17 +78,17 @@ public class SslClientInitializerTest {
private static final Function portProvider = channel -> SSL_PORT;
- @Rule public NettyRule nettyRule = new NettyRule();
+ @RegisterExtension NettyExtension nettyExtension = new NettyExtension();
- @Parameter(0)
- public SslProvider sslProvider;
-
- // We do our best effort to test all available SSL providers.
- @Parameters(name = "{0}")
- public static SslProvider[] data() {
- return OpenSsl.isAvailable()
- ? new SslProvider[] {SslProvider.JDK, SslProvider.OPENSSL}
- : new SslProvider[] {SslProvider.JDK};
+ @SuppressWarnings("unused")
+ static Stream provideTestCombinations() {
+ Stream.Builder args = Stream.builder();
+ // We do our best effort to test all available SSL providers.
+ args.add(Arguments.of(SslProvider.JDK));
+ if (OpenSsl.isAvailable()) {
+ args.add(Arguments.of(SslProvider.OPENSSL));
+ }
+ return args.build();
}
/** Saves the SNI hostname received by the server, if sent by the client. */
@@ -111,8 +109,9 @@ public class SslClientInitializerTest {
});
}
- @Test
- public void testSuccess_swappedInitializerWithSslHandler() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_swappedInitializerWithSslHandler(SslProvider sslProvider) {
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, portProvider, ImmutableList.of(), null, null);
@@ -127,8 +126,9 @@ public class SslClientInitializerTest {
assertThat(channel.isActive()).isTrue();
}
- @Test
- public void testSuccess_nullHost() {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_nullHost(SslProvider sslProvider) {
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, channel -> null, portProvider, ImmutableList.of(), null, null);
@@ -139,8 +139,9 @@ public class SslClientInitializerTest {
assertThat(channel.isActive()).isFalse();
}
- @Test
- public void testSuccess_nullPort() {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_nullPort(SslProvider sslProvider) {
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, channel -> null, ImmutableList.of(), null, null);
@@ -151,25 +152,29 @@ public class SslClientInitializerTest {
assertThat(channel.isActive()).isFalse();
}
- @Test
- public void testFailure_defaultTrustManager_rejectSelfSignedCert() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_defaultTrustManager_rejectSelfSignedCert(SslProvider sslProvider)
+ throws Exception {
SelfSignedCaCertificate ssc = SelfSignedCaCertificate.create(SSL_HOST);
LocalAddress localAddress =
new LocalAddress("DEFAULT_TRUST_MANAGER_REJECT_SELF_SIGNED_CERT_" + sslProvider);
- nettyRule.setUpServer(localAddress, getServerHandler(false, ssc.key(), ssc.cert()));
+ nettyExtension.setUpServer(localAddress, getServerHandler(false, ssc.key(), ssc.cert()));
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, portProvider, ImmutableList.of(), null, null);
- nettyRule.setUpClient(localAddress, sslClientInitializer);
+ nettyExtension.setUpClient(localAddress, sslClientInitializer);
// The connection is now terminated, both the client side and the server side should get
// exceptions.
- nettyRule.assertThatClientRootCause().isInstanceOf(CertPathBuilderException.class);
- nettyRule.assertThatServerRootCause().isInstanceOf(SSLException.class);
- assertThat(nettyRule.getClientChannel().isActive()).isFalse();
+ nettyExtension.assertThatClientRootCause().isInstanceOf(CertPathBuilderException.class);
+ nettyExtension.assertThatServerRootCause().isInstanceOf(SSLException.class);
+ assertThat(nettyExtension.getClientChannel().isActive()).isFalse();
}
- @Test
- public void testSuccess_customTrustManager_acceptCertSignedByTrustedCa() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_customTrustManager_acceptCertSignedByTrustedCa(SslProvider sslProvider)
+ throws Exception {
LocalAddress localAddress =
new LocalAddress("CUSTOM_TRUST_MANAGER_ACCEPT_CERT_SIGNED_BY_TRUSTED_CA_" + sslProvider);
@@ -182,23 +187,24 @@ public class SslClientInitializerTest {
// Set up the server to use the signed cert and private key to perform handshake;
PrivateKey privateKey = keyPair.getPrivate();
- nettyRule.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
+ nettyExtension.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
// Set up the client to trust the self signed cert used to sign the cert that server provides.
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, portProvider, ImmutableList.of(ssc.cert()), null, null);
- nettyRule.setUpClient(localAddress, sslClientInitializer);
+ nettyExtension.setUpClient(localAddress, sslClientInitializer);
- setUpSslChannel(nettyRule.getClientChannel(), cert);
- nettyRule.assertThatMessagesWork();
+ setUpSslChannel(nettyExtension.getClientChannel(), cert);
+ nettyExtension.assertThatMessagesWork();
// Verify that the SNI extension is sent during handshake.
assertThat(sniHostReceived).isEqualTo(SSL_HOST);
}
- @Test
- public void testFailure_customTrustManager_serverCertExpired() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_customTrustManager_serverCertExpired(SslProvider sslProvider) throws Exception {
LocalAddress localAddress =
new LocalAddress("CUSTOM_TRUST_MANAGER_SERVE_CERT_EXPIRED_" + sslProvider);
@@ -217,22 +223,24 @@ public class SslClientInitializerTest {
// Set up the server to use the signed cert and private key to perform handshake;
PrivateKey privateKey = keyPair.getPrivate();
- nettyRule.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
+ nettyExtension.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
// Set up the client to trust the self signed cert used to sign the cert that server provides.
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, portProvider, ImmutableList.of(ssc.cert()), null, null);
- nettyRule.setUpClient(localAddress, sslClientInitializer);
+ nettyExtension.setUpClient(localAddress, sslClientInitializer);
verifySslException(
- nettyRule.getClientChannel(),
+ nettyExtension.getClientChannel(),
channel -> channel.pipeline().get(SslHandler.class).handshakeFuture().get(),
CertificateExpiredException.class);
}
- @Test
- public void testFailure_customTrustManager_serverCertNotYetValid() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_customTrustManager_serverCertNotYetValid(SslProvider sslProvider)
+ throws Exception {
LocalAddress localAddress =
new LocalAddress("CUSTOM_TRUST_MANAGER_SERVE_CERT_NOT_YET_VALID_" + sslProvider);
@@ -251,23 +259,24 @@ public class SslClientInitializerTest {
// Set up the server to use the signed cert and private key to perform handshake;
PrivateKey privateKey = keyPair.getPrivate();
- nettyRule.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
+ nettyExtension.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
// Set up the client to trust the self signed cert used to sign the cert that server provides.
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, portProvider, ImmutableList.of(ssc.cert()), null, null);
- nettyRule.setUpClient(localAddress, sslClientInitializer);
+ nettyExtension.setUpClient(localAddress, sslClientInitializer);
verifySslException(
- nettyRule.getClientChannel(),
+ nettyExtension.getClientChannel(),
channel -> channel.pipeline().get(SslHandler.class).handshakeFuture().get(),
CertificateNotYetValidException.class);
}
- @Test
- public void testSuccess_customTrustManager_acceptSelfSignedCert_clientCertRequired()
- throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_customTrustManager_acceptSelfSignedCert_clientCertRequired(
+ SslProvider sslProvider) throws Exception {
LocalAddress localAddress =
new LocalAddress(
"CUSTOM_TRUST_MANAGER_ACCEPT_SELF_SIGNED_CERT_CLIENT_CERT_REQUIRED_" + sslProvider);
@@ -276,7 +285,8 @@ public class SslClientInitializerTest {
SelfSignedCaCertificate clientSsc = SelfSignedCaCertificate.create();
// Set up the server to require client certificate.
- nettyRule.setUpServer(localAddress, getServerHandler(true, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpServer(
+ localAddress, getServerHandler(true, serverSsc.key(), serverSsc.cert()));
// Set up the client to trust the server certificate and use the client certificate.
SslClientInitializer sslClientInitializer =
@@ -287,10 +297,10 @@ public class SslClientInitializerTest {
ImmutableList.of(serverSsc.cert()),
() -> clientSsc.key(),
() -> ImmutableList.of(clientSsc.cert()));
- nettyRule.setUpClient(localAddress, sslClientInitializer);
+ nettyExtension.setUpClient(localAddress, sslClientInitializer);
- SSLSession sslSession = setUpSslChannel(nettyRule.getClientChannel(), serverSsc.cert());
- nettyRule.assertThatMessagesWork();
+ SSLSession sslSession = setUpSslChannel(nettyExtension.getClientChannel(), serverSsc.cert());
+ nettyExtension.assertThatMessagesWork();
// Verify that the SNI extension is sent during handshake.
assertThat(sniHostReceived).isEqualTo(SSL_HOST);
@@ -302,8 +312,10 @@ public class SslClientInitializerTest {
assertThat(sslSession.getPeerCertificates()).asList().containsExactly(serverSsc.cert());
}
- @Test
- public void testFailure_customTrustManager_wrongHostnameInCertificate() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_customTrustManager_wrongHostnameInCertificate(SslProvider sslProvider)
+ throws Exception {
LocalAddress localAddress =
new LocalAddress("CUSTOM_TRUST_MANAGER_WRONG_HOSTNAME_" + sslProvider);
@@ -316,19 +328,19 @@ public class SslClientInitializerTest {
// Set up the server to use the signed cert and private key to perform handshake;
PrivateKey privateKey = keyPair.getPrivate();
- nettyRule.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
+ nettyExtension.setUpServer(localAddress, getServerHandler(false, privateKey, cert));
// Set up the client to trust the self signed cert used to sign the cert that server provides.
SslClientInitializer sslClientInitializer =
new SslClientInitializer<>(
sslProvider, hostProvider, portProvider, ImmutableList.of(ssc.cert()), null, null);
- nettyRule.setUpClient(localAddress, sslClientInitializer);
+ nettyExtension.setUpClient(localAddress, sslClientInitializer);
// When the client rejects the server cert due to wrong hostname, both the client and server
// should throw exceptions.
- nettyRule.assertThatClientRootCause().isInstanceOf(CertificateException.class);
- nettyRule.assertThatClientRootCause().hasMessageThat().contains(SSL_HOST);
- nettyRule.assertThatServerRootCause().isInstanceOf(SSLException.class);
- assertThat(nettyRule.getClientChannel().isActive()).isFalse();
+ nettyExtension.assertThatClientRootCause().isInstanceOf(CertificateException.class);
+ nettyExtension.assertThatClientRootCause().hasMessageThat().contains(SSL_HOST);
+ nettyExtension.assertThatServerRootCause().isInstanceOf(SSLException.class);
+ assertThat(nettyExtension.getClientChannel().isActive()).isFalse();
}
}
diff --git a/networking/src/test/java/google/registry/networking/handler/SslInitializerTestUtils.java b/networking/src/test/java/google/registry/networking/handler/SslInitializerTestUtils.java
index 0106275de..1f38beb40 100644
--- a/networking/src/test/java/google/registry/networking/handler/SslInitializerTestUtils.java
+++ b/networking/src/test/java/google/registry/networking/handler/SslInitializerTestUtils.java
@@ -15,7 +15,7 @@
package google.registry.networking.handler;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Throwables;
import google.registry.networking.util.SelfSignedCaCertificate;
diff --git a/networking/src/test/java/google/registry/networking/handler/SslServerInitializerTest.java b/networking/src/test/java/google/registry/networking/handler/SslServerInitializerTest.java
index 8b6a536a5..77dfa1eef 100644
--- a/networking/src/test/java/google/registry/networking/handler/SslServerInitializerTest.java
+++ b/networking/src/test/java/google/registry/networking/handler/SslServerInitializerTest.java
@@ -43,17 +43,16 @@ import java.security.cert.X509Certificate;
import java.time.Duration;
import java.time.Instant;
import java.util.Date;
+import java.util.stream.Stream;
import javax.net.ssl.SSLEngine;
import javax.net.ssl.SSLException;
import javax.net.ssl.SSLHandshakeException;
import javax.net.ssl.SSLParameters;
import javax.net.ssl.SSLSession;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
-import org.junit.runners.Parameterized.Parameter;
-import org.junit.runners.Parameterized.Parameters;
+import org.junit.jupiter.api.extension.RegisterExtension;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.Arguments;
+import org.junit.jupiter.params.provider.MethodSource;
/**
* Unit tests for {@link SslServerInitializer}.
@@ -66,8 +65,7 @@ import org.junit.runners.Parameterized.Parameters;
* The local addresses used in each test method must to be different, otherwise tests run in
* parallel may interfere with each other.
*/
-@RunWith(Parameterized.class)
-public class SslServerInitializerTest {
+class SslServerInitializerTest {
/** Fake host to test if the SSL engine gets the correct peer host. */
private static final String SSL_HOST = "www.example.tld";
@@ -75,22 +73,23 @@ public class SslServerInitializerTest {
/** Fake port to test if the SSL engine gets the correct peer port. */
private static final int SSL_PORT = 12345;
- @Rule public NettyRule nettyRule = new NettyRule();
+ @RegisterExtension NettyExtension nettyExtension = new NettyExtension();
- @Parameter(0)
- public SslProvider sslProvider;
-
- // We do our best effort to test all available SSL providers.
- @Parameters(name = "{0}")
- public static SslProvider[] data() {
- return OpenSsl.isAvailable()
- ? new SslProvider[] {SslProvider.OPENSSL, SslProvider.JDK}
- : new SslProvider[] {SslProvider.JDK};
+ @SuppressWarnings("unused")
+ static Stream provideTestCombinations() {
+ Stream.Builder args = Stream.builder();
+ // We do our best effort to test all available SSL providers.
+ args.add(Arguments.of(SslProvider.JDK));
+ if (OpenSsl.isAvailable()) {
+ args.add(Arguments.of(SslProvider.OPENSSL));
+ }
+ return args.build();
}
private ChannelHandler getServerHandler(
boolean requireClientCert,
boolean validateClientCert,
+ SslProvider sslProvider,
PrivateKey privateKey,
X509Certificate... certificates) {
return new SslServerInitializer(
@@ -102,7 +101,10 @@ public class SslServerInitializerTest {
}
private ChannelHandler getClientHandler(
- X509Certificate trustedCertificate, PrivateKey privateKey, X509Certificate certificate) {
+ SslProvider sslProvider,
+ X509Certificate trustedCertificate,
+ PrivateKey privateKey,
+ X509Certificate certificate) {
return new ChannelInitializer() {
@Override
protected void initChannel(LocalChannel ch) throws Exception {
@@ -125,8 +127,9 @@ public class SslServerInitializerTest {
};
}
- @Test
- public void testSuccess_swappedInitializerWithSslHandler() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_swappedInitializerWithSslHandler(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate ssc = SelfSignedCaCertificate.create(SSL_HOST);
SslServerInitializer sslServerInitializer =
new SslServerInitializer<>(
@@ -145,19 +148,22 @@ public class SslServerInitializerTest {
assertThat(channel.isActive()).isTrue();
}
- @Test
- public void testSuccess_trustAnyClientCert() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_trustAnyClientCert(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate serverSsc = SelfSignedCaCertificate.create(SSL_HOST);
LocalAddress localAddress = new LocalAddress("TRUST_ANY_CLIENT_CERT_" + sslProvider);
- nettyRule.setUpServer(
- localAddress, getServerHandler(true, false, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpServer(
+ localAddress,
+ getServerHandler(true, false, sslProvider, serverSsc.key(), serverSsc.cert()));
SelfSignedCaCertificate clientSsc = SelfSignedCaCertificate.create();
- nettyRule.setUpClient(
- localAddress, getClientHandler(serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
+ nettyExtension.setUpClient(
+ localAddress,
+ getClientHandler(sslProvider, serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
- SSLSession sslSession = setUpSslChannel(nettyRule.getClientChannel(), serverSsc.cert());
- nettyRule.assertThatMessagesWork();
+ SSLSession sslSession = setUpSslChannel(nettyExtension.getClientChannel(), serverSsc.cert());
+ nettyExtension.assertThatMessagesWork();
// Verify that the SSL session gets the client cert. Note that this SslSession is for the client
// channel, therefore its local certificates are the remote certificates of the SslSession for
@@ -166,59 +172,66 @@ public class SslServerInitializerTest {
assertThat(sslSession.getPeerCertificates()).asList().containsExactly(serverSsc.cert());
}
- @Test
- public void testFailure_clientCertExpired() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_clientCertExpired(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate serverSsc = SelfSignedCaCertificate.create(SSL_HOST);
LocalAddress localAddress = new LocalAddress("CLIENT_CERT_EXPIRED_" + sslProvider);
- nettyRule.setUpServer(
- localAddress, getServerHandler(true, true, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpServer(
+ localAddress, getServerHandler(true, true, sslProvider, serverSsc.key(), serverSsc.cert()));
SelfSignedCaCertificate clientSsc =
SelfSignedCaCertificate.create(
"CLIENT",
Date.from(Instant.now().minus(Duration.ofDays(2))),
Date.from(Instant.now().minus(Duration.ofDays(1))));
- nettyRule.setUpClient(
- localAddress, getClientHandler(serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
+ nettyExtension.setUpClient(
+ localAddress,
+ getClientHandler(sslProvider, serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
verifySslException(
- nettyRule.getServerChannel(),
+ nettyExtension.getServerChannel(),
channel -> channel.attr(CLIENT_CERTIFICATE_PROMISE_KEY).get().get(),
CertificateExpiredException.class);
}
- @Test
- public void testFailure_clientCertNotYetValid() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_clientCertNotYetValid(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate serverSsc = SelfSignedCaCertificate.create(SSL_HOST);
LocalAddress localAddress = new LocalAddress("CLIENT_CERT_EXPIRED_" + sslProvider);
- nettyRule.setUpServer(
- localAddress, getServerHandler(true, true, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpServer(
+ localAddress, getServerHandler(true, true, sslProvider, serverSsc.key(), serverSsc.cert()));
SelfSignedCaCertificate clientSsc =
SelfSignedCaCertificate.create(
"CLIENT",
Date.from(Instant.now().plus(Duration.ofDays(1))),
Date.from(Instant.now().plus(Duration.ofDays(2))));
- nettyRule.setUpClient(
- localAddress, getClientHandler(serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
+ nettyExtension.setUpClient(
+ localAddress,
+ getClientHandler(sslProvider, serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
verifySslException(
- nettyRule.getServerChannel(),
+ nettyExtension.getServerChannel(),
channel -> channel.attr(CLIENT_CERTIFICATE_PROMISE_KEY).get().get(),
CertificateNotYetValidException.class);
}
- @Test
- public void testSuccess_doesNotRequireClientCert() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_doesNotRequireClientCert(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate serverSsc = SelfSignedCaCertificate.create(SSL_HOST);
LocalAddress localAddress = new LocalAddress("DOES_NOT_REQUIRE_CLIENT_CERT_" + sslProvider);
- nettyRule.setUpServer(
- localAddress, getServerHandler(false, false, serverSsc.key(), serverSsc.cert()));
- nettyRule.setUpClient(localAddress, getClientHandler(serverSsc.cert(), null, null));
+ nettyExtension.setUpServer(
+ localAddress,
+ getServerHandler(false, false, sslProvider, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpClient(
+ localAddress, getClientHandler(sslProvider, serverSsc.cert(), null, null));
- SSLSession sslSession = setUpSslChannel(nettyRule.getClientChannel(), serverSsc.cert());
- nettyRule.assertThatMessagesWork();
+ SSLSession sslSession = setUpSslChannel(nettyExtension.getClientChannel(), serverSsc.cert());
+ nettyExtension.assertThatMessagesWork();
// Verify that the SSL session does not contain any client cert. Note that this SslSession is
// for the client channel, therefore its local certificates are the remote certificates of the
@@ -227,32 +240,38 @@ public class SslServerInitializerTest {
assertThat(sslSession.getPeerCertificates()).asList().containsExactly(serverSsc.cert());
}
- @Test
- public void testSuccess_CertSignedByOtherCA() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testSuccess_CertSignedByOtherCa(SslProvider sslProvider) throws Exception {
// The self-signed cert of the CA.
SelfSignedCaCertificate caSsc = SelfSignedCaCertificate.create();
KeyPair keyPair = getKeyPair();
X509Certificate serverCert = signKeyPair(caSsc, keyPair, SSL_HOST);
LocalAddress localAddress = new LocalAddress("CERT_SIGNED_BY_OTHER_CA_" + sslProvider);
- nettyRule.setUpServer(
+ nettyExtension.setUpServer(
localAddress,
getServerHandler(
true,
false,
+ sslProvider,
keyPair.getPrivate(),
// Serving both the server cert, and the CA cert
serverCert,
caSsc.cert()));
SelfSignedCaCertificate clientSsc = SelfSignedCaCertificate.create();
- nettyRule.setUpClient(
+ nettyExtension.setUpClient(
localAddress,
getClientHandler(
+ sslProvider,
// Client trusts the CA cert
- caSsc.cert(), clientSsc.key(), clientSsc.cert()));
+ caSsc.cert(),
+ clientSsc.key(),
+ clientSsc.cert()));
- SSLSession sslSession = setUpSslChannel(nettyRule.getClientChannel(), serverCert, caSsc.cert());
- nettyRule.assertThatMessagesWork();
+ SSLSession sslSession =
+ setUpSslChannel(nettyExtension.getClientChannel(), serverCert, caSsc.cert());
+ nettyExtension.assertThatMessagesWork();
assertThat(sslSession.getLocalCertificates()).asList().containsExactly(clientSsc.cert());
assertThat(sslSession.getPeerCertificates())
@@ -261,16 +280,19 @@ public class SslServerInitializerTest {
.inOrder();
}
- @Test
- public void testFailure_requireClientCertificate() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_requireClientCertificate(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate serverSsc = SelfSignedCaCertificate.create(SSL_HOST);
LocalAddress localAddress = new LocalAddress("REQUIRE_CLIENT_CERT_" + sslProvider);
- nettyRule.setUpServer(
- localAddress, getServerHandler(true, false, serverSsc.key(), serverSsc.cert()));
- nettyRule.setUpClient(
+ nettyExtension.setUpServer(
+ localAddress,
+ getServerHandler(true, false, sslProvider, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpClient(
localAddress,
getClientHandler(
+ sslProvider,
serverSsc.cert(),
// No client cert/private key used.
null,
@@ -278,27 +300,30 @@ public class SslServerInitializerTest {
// When the server rejects the client during handshake due to lack of client certificate, both
// should throw exceptions.
- nettyRule.assertThatServerRootCause().isInstanceOf(SSLHandshakeException.class);
- nettyRule.assertThatClientRootCause().isInstanceOf(SSLException.class);
- assertThat(nettyRule.getClientChannel().isActive()).isFalse();
+ nettyExtension.assertThatServerRootCause().isInstanceOf(SSLHandshakeException.class);
+ nettyExtension.assertThatClientRootCause().isInstanceOf(SSLException.class);
+ assertThat(nettyExtension.getClientChannel().isActive()).isFalse();
}
- @Test
- public void testFailure_wrongHostnameInCertificate() throws Exception {
+ @ParameterizedTest
+ @MethodSource("provideTestCombinations")
+ void testFailure_wrongHostnameInCertificate(SslProvider sslProvider) throws Exception {
SelfSignedCaCertificate serverSsc = SelfSignedCaCertificate.create("wrong.com");
LocalAddress localAddress = new LocalAddress("WRONG_HOSTNAME_" + sslProvider);
- nettyRule.setUpServer(
- localAddress, getServerHandler(true, false, serverSsc.key(), serverSsc.cert()));
+ nettyExtension.setUpServer(
+ localAddress,
+ getServerHandler(true, false, sslProvider, serverSsc.key(), serverSsc.cert()));
SelfSignedCaCertificate clientSsc = SelfSignedCaCertificate.create();
- nettyRule.setUpClient(
- localAddress, getClientHandler(serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
+ nettyExtension.setUpClient(
+ localAddress,
+ getClientHandler(sslProvider, serverSsc.cert(), clientSsc.key(), clientSsc.cert()));
// When the client rejects the server cert due to wrong hostname, both the server and the client
// throw exceptions.
- nettyRule.assertThatClientRootCause().isInstanceOf(CertificateException.class);
- nettyRule.assertThatClientRootCause().hasMessageThat().contains(SSL_HOST);
- nettyRule.assertThatServerRootCause().isInstanceOf(SSLException.class);
- assertThat(nettyRule.getClientChannel().isActive()).isFalse();
+ nettyExtension.assertThatClientRootCause().isInstanceOf(CertificateException.class);
+ nettyExtension.assertThatClientRootCause().hasMessageThat().contains(SSL_HOST);
+ nettyExtension.assertThatServerRootCause().isInstanceOf(SSLException.class);
+ assertThat(nettyExtension.getClientChannel().isActive()).isFalse();
}
}
diff --git a/networking/src/test/java/google/registry/networking/module/CertificateSupplierModuleTest.java b/networking/src/test/java/google/registry/networking/module/CertificateSupplierModuleTest.java
index 38f4ef476..9b4a62216 100644
--- a/networking/src/test/java/google/registry/networking/module/CertificateSupplierModuleTest.java
+++ b/networking/src/test/java/google/registry/networking/module/CertificateSupplierModuleTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.networking.handler.SslInitializerTestUtils.getKeyPair;
import static google.registry.networking.handler.SslInitializerTestUtils.signKeyPair;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import dagger.BindsInstance;
@@ -38,14 +38,11 @@ import java.util.function.Supplier;
import javax.inject.Named;
import javax.inject.Singleton;
import org.bouncycastle.openssl.jcajce.JcaPEMWriter;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link CertificateSupplierModule}. */
-@RunWith(JUnit4.class)
-public class CertificateSupplierModuleTest {
+class CertificateSupplierModuleTest {
private SelfSignedCaCertificate ssc;
private PrivateKey key;
@@ -60,8 +57,8 @@ public class CertificateSupplierModuleTest {
.build();
}
- @Before
- public void setUp() throws Exception {
+ @BeforeEach
+ void beforeEach() throws Exception {
ssc = SelfSignedCaCertificate.create();
KeyPair keyPair = getKeyPair();
key = keyPair.getPrivate();
@@ -69,14 +66,14 @@ public class CertificateSupplierModuleTest {
}
@Test
- public void testSuccess() throws Exception {
+ void testSuccess() throws Exception {
component = createComponentForPem(cert, ssc.cert(), key);
assertThat(component.privateKeySupplier().get()).isEqualTo(key);
assertThat(component.certificatesSupplier().get()).containsExactly(cert, ssc.cert()).inOrder();
}
@Test
- public void testSuccess_certificateChainNotContinuous() throws Exception {
+ void testSuccess_certificateChainNotContinuous() throws Exception {
component = createComponentForPem(cert, key, ssc.cert());
assertThat(component.privateKeySupplier().get()).isEqualTo(key);
assertThat(component.certificatesSupplier().get()).containsExactly(cert, ssc.cert()).inOrder();
@@ -84,7 +81,7 @@ public class CertificateSupplierModuleTest {
@Test
@SuppressWarnings("ReturnValueIgnored")
- public void testFailure_noPrivateKey() throws Exception {
+ void testFailure_noPrivateKey() throws Exception {
component = createComponentForPem(cert, ssc.cert());
IllegalStateException thrown =
assertThrows(IllegalStateException.class, () -> component.privateKeySupplier().get());
@@ -93,7 +90,7 @@ public class CertificateSupplierModuleTest {
@Test
@SuppressWarnings("ReturnValueIgnored")
- public void testFailure_twoPrivateKeys() throws Exception {
+ void testFailure_twoPrivateKeys() throws Exception {
component = createComponentForPem(cert, ssc.cert(), key, ssc.key());
IllegalStateException thrown =
assertThrows(IllegalStateException.class, () -> component.privateKeySupplier().get());
@@ -102,7 +99,7 @@ public class CertificateSupplierModuleTest {
@Test
@SuppressWarnings("ReturnValueIgnored")
- public void testFailure_certificatesOutOfOrder() throws Exception {
+ void testFailure_certificatesOutOfOrder() throws Exception {
component = createComponentForPem(ssc.cert(), cert, key);
IllegalStateException thrown =
assertThrows(IllegalStateException.class, () -> component.certificatesSupplier().get());
@@ -111,7 +108,7 @@ public class CertificateSupplierModuleTest {
@Test
@SuppressWarnings("ReturnValueIgnored")
- public void testFailure_noCertificates() throws Exception {
+ void testFailure_noCertificates() throws Exception {
component = createComponentForPem(key);
IllegalStateException thrown =
assertThrows(IllegalStateException.class, () -> component.certificatesSupplier().get());
diff --git a/prober/gradle/dependency-locks/testCompile.lockfile b/prober/gradle/dependency-locks/testCompile.lockfile
index 389020e47..cecda02f9 100644
--- a/prober/gradle/dependency-locks/testCompile.lockfile
+++ b/prober/gradle/dependency-locks/testCompile.lockfile
@@ -60,6 +60,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/prober/gradle/dependency-locks/testCompileClasspath.lockfile b/prober/gradle/dependency-locks/testCompileClasspath.lockfile
index 389020e47..cecda02f9 100644
--- a/prober/gradle/dependency-locks/testCompileClasspath.lockfile
+++ b/prober/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -60,6 +60,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/prober/gradle/dependency-locks/testRuntime.lockfile b/prober/gradle/dependency-locks/testRuntime.lockfile
index 389020e47..cecda02f9 100644
--- a/prober/gradle/dependency-locks/testRuntime.lockfile
+++ b/prober/gradle/dependency-locks/testRuntime.lockfile
@@ -60,6 +60,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/prober/gradle/dependency-locks/testRuntimeClasspath.lockfile b/prober/gradle/dependency-locks/testRuntimeClasspath.lockfile
index 389020e47..cecda02f9 100644
--- a/prober/gradle/dependency-locks/testRuntimeClasspath.lockfile
+++ b/prober/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -60,6 +60,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/prober/src/test/java/google/registry/monitoring/blackbox/ProbingStepTest.java b/prober/src/test/java/google/registry/monitoring/blackbox/ProbingStepTest.java
index a14514fc5..c27b073d1 100644
--- a/prober/src/test/java/google/registry/monitoring/blackbox/ProbingStepTest.java
+++ b/prober/src/test/java/google/registry/monitoring/blackbox/ProbingStepTest.java
@@ -30,7 +30,7 @@ import google.registry.monitoring.blackbox.handler.TestActionHandler;
import google.registry.monitoring.blackbox.message.OutboundMessageType;
import google.registry.monitoring.blackbox.message.TestMessage;
import google.registry.monitoring.blackbox.token.Token;
-import google.registry.networking.handler.NettyRule;
+import google.registry.networking.handler.NettyExtension;
import io.netty.bootstrap.Bootstrap;
import io.netty.channel.ChannelFuture;
import io.netty.channel.ChannelHandler;
@@ -40,15 +40,15 @@ import io.netty.channel.local.LocalAddress;
import io.netty.channel.local.LocalChannel;
import io.netty.channel.nio.NioEventLoopGroup;
import org.joda.time.Duration;
-import org.junit.Rule;
-import org.junit.Test;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.extension.RegisterExtension;
import org.mockito.Mockito;
/**
* Unit Tests for {@link ProbingSequence}s and {@link ProbingStep}s and their specific
- * implementations
+ * implementations.
*/
-public class ProbingStepTest {
+class ProbingStepTest {
/** Basic Constants necessary for tests */
private static final String ADDRESS_NAME = "TEST_ADDRESS";
@@ -61,12 +61,13 @@ public class ProbingStepTest {
private final EventLoopGroup eventLoopGroup = new NioEventLoopGroup(1);
private final Bootstrap bootstrap =
new Bootstrap().group(eventLoopGroup).channel(LocalChannel.class);
+
/** Used for testing how well probing step can create connection to blackbox server */
- @Rule public NettyRule nettyRule = new NettyRule();
+ @RegisterExtension NettyExtension nettyExtension = new NettyExtension();
/**
- * The two main handlers we need in any test pipeline used that connects to {@link NettyRule's
- * server}
+ * The two main handlers we need in any test pipeline used that connects to {@link NettyExtension
+ * 's server}
*/
private ActionHandler testHandler = new TestActionHandler();
@@ -87,7 +88,7 @@ public class ProbingStepTest {
}
@Test
- public void testProbingActionGenerate_embeddedChannel() throws UndeterminedStateException {
+ void testProbingActionGenerate_embeddedChannel() throws UndeterminedStateException {
// Sets up Protocol to represent existing channel connection.
Protocol testProtocol =
Protocol.builder()
@@ -125,7 +126,7 @@ public class ProbingStepTest {
}
@Test
- public void testProbingActionGenerate_newChannel() throws UndeterminedStateException {
+ void testProbingActionGenerate_newChannel() throws UndeterminedStateException {
// Sets up Protocol for when we create a new channel.
Protocol testProtocol =
Protocol.builder()
@@ -149,7 +150,7 @@ public class ProbingStepTest {
Token testToken = testToken(ADDRESS_NAME);
// Sets up server listening at LocalAddress so generated action can have successful connection.
- nettyRule.setUpServer(address);
+ nettyExtension.setUpServer(address);
ProbingAction testAction = testStep.generateAction(testToken);
diff --git a/prober/src/test/java/google/registry/monitoring/blackbox/connection/ProbingActionTest.java b/prober/src/test/java/google/registry/monitoring/blackbox/connection/ProbingActionTest.java
index 68d1254d1..acf882506 100644
--- a/prober/src/test/java/google/registry/monitoring/blackbox/connection/ProbingActionTest.java
+++ b/prober/src/test/java/google/registry/monitoring/blackbox/connection/ProbingActionTest.java
@@ -24,7 +24,7 @@ import google.registry.monitoring.blackbox.handler.ActionHandler;
import google.registry.monitoring.blackbox.handler.ConversionHandler;
import google.registry.monitoring.blackbox.handler.TestActionHandler;
import google.registry.monitoring.blackbox.message.TestMessage;
-import google.registry.networking.handler.NettyRule;
+import google.registry.networking.handler.NettyExtension;
import io.netty.bootstrap.Bootstrap;
import io.netty.buffer.ByteBuf;
import io.netty.buffer.Unpooled;
@@ -34,11 +34,9 @@ import io.netty.channel.embedded.EmbeddedChannel;
import io.netty.channel.local.LocalAddress;
import io.netty.channel.local.LocalChannel;
import org.joda.time.Duration;
-import org.junit.Ignore;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Disabled;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.extension.RegisterExtension;
/**
* Unit tests for {@link ProbingAction} subtypes
@@ -46,8 +44,7 @@ import org.junit.runners.JUnit4;
* Attempts to test how well each {@link ProbingAction} works with an {@link ActionHandler}
* subtype when receiving to all possible types of responses
*/
-@RunWith(JUnit4.class)
-public class ProbingActionTest {
+class ProbingActionTest {
private static final String TEST_MESSAGE = "MESSAGE_TEST";
private static final String SECONDARY_TEST_MESSAGE = "SECONDARY_MESSAGE_TEST";
@@ -55,7 +52,7 @@ public class ProbingActionTest {
private static final String ADDRESS_NAME = "TEST_ADDRESS";
private static final int TEST_PORT = 0;
- @Rule public NettyRule nettyRule = new NettyRule();
+ @RegisterExtension NettyExtension nettyExtension = new NettyExtension();
/**
* We use custom Test {@link ActionHandler} and {@link ConversionHandler} so test depends only on
@@ -67,9 +64,9 @@ public class ProbingActionTest {
// TODO - Currently, this test fails to receive outbound messages from the embedded channel, which
// we will fix in a later release.
- @Ignore
+ @Disabled
@Test
- public void testSuccess_existingChannel() {
+ void testSuccess_existingChannel() {
// setup
EmbeddedChannel channel = new EmbeddedChannel(conversionHandler, testHandler);
channel.attr(CONNECTION_FUTURE_KEY).set(channel.newSucceededFuture());
@@ -118,12 +115,12 @@ public class ProbingActionTest {
}
@Test
- public void testSuccess_newChannel() throws Exception {
+ void testSuccess_newChannel() throws Exception {
// setup
LocalAddress address = new LocalAddress(ADDRESS_NAME);
Bootstrap bootstrap =
- new Bootstrap().group(nettyRule.getEventLoopGroup()).channel(LocalChannel.class);
+ new Bootstrap().group(nettyExtension.getEventLoopGroup()).channel(LocalChannel.class);
// Sets up a Protocol corresponding to when a new connection is created.
Protocol protocol =
@@ -134,7 +131,7 @@ public class ProbingActionTest {
.setPersistentConnection(false)
.build();
- nettyRule.setUpServer(address);
+ nettyExtension.setUpServer(address);
// Sets up a ProbingAction with existing channel using test specified attributes.
ProbingAction action =
@@ -150,7 +147,7 @@ public class ProbingActionTest {
ChannelFuture future = action.call();
// Tests to see if message is properly sent to remote server
- nettyRule.assertReceivedMessage(TEST_MESSAGE);
+ nettyExtension.assertReceivedMessage(TEST_MESSAGE);
future = future.syncUninterruptibly();
// Tests to see that, since server responds, we have set future to true
diff --git a/prober/src/test/java/google/registry/monitoring/blackbox/handler/EppActionHandlerTest.java b/prober/src/test/java/google/registry/monitoring/blackbox/handler/EppActionHandlerTest.java
index 3fed26412..76b2ed1da 100644
--- a/prober/src/test/java/google/registry/monitoring/blackbox/handler/EppActionHandlerTest.java
+++ b/prober/src/test/java/google/registry/monitoring/blackbox/handler/EppActionHandlerTest.java
@@ -15,7 +15,7 @@
package google.registry.monitoring.blackbox.handler;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.monitoring.blackbox.exception.EppClientException;
import google.registry.monitoring.blackbox.exception.FailureException;
diff --git a/prober/src/test/java/google/registry/monitoring/blackbox/message/EppMessageTest.java b/prober/src/test/java/google/registry/monitoring/blackbox/message/EppMessageTest.java
index 2be978507..18b5e8472 100644
--- a/prober/src/test/java/google/registry/monitoring/blackbox/message/EppMessageTest.java
+++ b/prober/src/test/java/google/registry/monitoring/blackbox/message/EppMessageTest.java
@@ -16,7 +16,7 @@ package google.registry.monitoring.blackbox.message;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.monitoring.blackbox.exception.EppClientException;
import google.registry.monitoring.blackbox.exception.FailureException;
diff --git a/proxy/gradle/dependency-locks/testCompile.lockfile b/proxy/gradle/dependency-locks/testCompile.lockfile
index 43f9320ab..c92e9cae7 100644
--- a/proxy/gradle/dependency-locks/testCompile.lockfile
+++ b/proxy/gradle/dependency-locks/testCompile.lockfile
@@ -65,6 +65,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/proxy/gradle/dependency-locks/testCompileClasspath.lockfile b/proxy/gradle/dependency-locks/testCompileClasspath.lockfile
index 43f9320ab..c92e9cae7 100644
--- a/proxy/gradle/dependency-locks/testCompileClasspath.lockfile
+++ b/proxy/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -65,6 +65,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/proxy/gradle/dependency-locks/testRuntime.lockfile b/proxy/gradle/dependency-locks/testRuntime.lockfile
index 43f9320ab..c92e9cae7 100644
--- a/proxy/gradle/dependency-locks/testRuntime.lockfile
+++ b/proxy/gradle/dependency-locks/testRuntime.lockfile
@@ -65,6 +65,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/proxy/gradle/dependency-locks/testRuntimeClasspath.lockfile b/proxy/gradle/dependency-locks/testRuntimeClasspath.lockfile
index 43f9320ab..c92e9cae7 100644
--- a/proxy/gradle/dependency-locks/testRuntimeClasspath.lockfile
+++ b/proxy/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -65,6 +65,7 @@ org.checkerframework:checker-qual:2.11.1
org.hamcrest:hamcrest-core:1.3
org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
+org.junit.jupiter:junit-jupiter-params:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
org.junit.vintage:junit-vintage-engine:5.6.2
diff --git a/proxy/src/test/java/google/registry/proxy/EppProtocolModuleTest.java b/proxy/src/test/java/google/registry/proxy/EppProtocolModuleTest.java
index c568a6667..30c211070 100644
--- a/proxy/src/test/java/google/registry/proxy/EppProtocolModuleTest.java
+++ b/proxy/src/test/java/google/registry/proxy/EppProtocolModuleTest.java
@@ -20,7 +20,7 @@ import static google.registry.proxy.handler.ProxyProtocolHandler.REMOTE_ADDRESS_
import static google.registry.util.ResourceUtils.readResourceBytes;
import static google.registry.util.X509Utils.getCertificateHash;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Throwables;
import google.registry.networking.util.SelfSignedCaCertificate;
diff --git a/proxy/src/test/java/google/registry/proxy/ProxyModuleTest.java b/proxy/src/test/java/google/registry/proxy/ProxyModuleTest.java
index 59b9014d4..042084970 100644
--- a/proxy/src/test/java/google/registry/proxy/ProxyModuleTest.java
+++ b/proxy/src/test/java/google/registry/proxy/ProxyModuleTest.java
@@ -17,7 +17,7 @@ package google.registry.proxy;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.proxy.ProxyConfig.Environment.LOCAL;
import static google.registry.proxy.ProxyConfig.getProxyConfig;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.beust.jcommander.ParameterException;
import google.registry.proxy.ProxyConfig.Environment;
diff --git a/proxy/src/test/java/google/registry/proxy/WhoisProtocolModuleTest.java b/proxy/src/test/java/google/registry/proxy/WhoisProtocolModuleTest.java
index 03beade4e..c2640b309 100644
--- a/proxy/src/test/java/google/registry/proxy/WhoisProtocolModuleTest.java
+++ b/proxy/src/test/java/google/registry/proxy/WhoisProtocolModuleTest.java
@@ -19,7 +19,7 @@ import static google.registry.proxy.TestUtils.makeWhoisHttpRequest;
import static google.registry.proxy.TestUtils.makeWhoisHttpResponse;
import static java.nio.charset.StandardCharsets.US_ASCII;
import static java.util.stream.Collectors.joining;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.base.Throwables;
import google.registry.proxy.handler.HttpsRelayServiceHandler.NonOkHttpResponseException;
diff --git a/proxy/src/test/java/google/registry/proxy/handler/BackendMetricsHandlerTest.java b/proxy/src/test/java/google/registry/proxy/handler/BackendMetricsHandlerTest.java
index 6df75efba..1b24bb636 100644
--- a/proxy/src/test/java/google/registry/proxy/handler/BackendMetricsHandlerTest.java
+++ b/proxy/src/test/java/google/registry/proxy/handler/BackendMetricsHandlerTest.java
@@ -22,7 +22,7 @@ import static google.registry.proxy.TestUtils.makeHttpPostRequest;
import static google.registry.proxy.TestUtils.makeHttpResponse;
import static google.registry.proxy.handler.EppServiceHandler.CLIENT_CERTIFICATE_HASH_KEY;
import static google.registry.proxy.handler.RelayHandler.RELAY_CHANNEL_KEY;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/proxy/src/test/java/google/registry/proxy/handler/EppQuotaHandlerTest.java b/proxy/src/test/java/google/registry/proxy/handler/EppQuotaHandlerTest.java
index db7da4514..28bd55c07 100644
--- a/proxy/src/test/java/google/registry/proxy/handler/EppQuotaHandlerTest.java
+++ b/proxy/src/test/java/google/registry/proxy/handler/EppQuotaHandlerTest.java
@@ -17,7 +17,7 @@ package google.registry.proxy.handler;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.proxy.Protocol.PROTOCOL_KEY;
import static google.registry.proxy.handler.EppServiceHandler.CLIENT_CERTIFICATE_HASH_KEY;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/proxy/src/test/java/google/registry/proxy/handler/EppServiceHandlerTest.java b/proxy/src/test/java/google/registry/proxy/handler/EppServiceHandlerTest.java
index 0e97db475..f3474967f 100644
--- a/proxy/src/test/java/google/registry/proxy/handler/EppServiceHandlerTest.java
+++ b/proxy/src/test/java/google/registry/proxy/handler/EppServiceHandlerTest.java
@@ -21,7 +21,7 @@ import static google.registry.proxy.TestUtils.makeEppHttpResponse;
import static google.registry.proxy.handler.ProxyProtocolHandler.REMOTE_ADDRESS_KEY;
import static google.registry.util.X509Utils.getCertificateHash;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/proxy/src/test/java/google/registry/proxy/handler/FrontendMetricsHandlerTest.java b/proxy/src/test/java/google/registry/proxy/handler/FrontendMetricsHandlerTest.java
index a7fca938f..42c382621 100644
--- a/proxy/src/test/java/google/registry/proxy/handler/FrontendMetricsHandlerTest.java
+++ b/proxy/src/test/java/google/registry/proxy/handler/FrontendMetricsHandlerTest.java
@@ -17,7 +17,7 @@ package google.registry.proxy.handler;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.proxy.Protocol.PROTOCOL_KEY;
import static google.registry.proxy.handler.EppServiceHandler.CLIENT_CERTIFICATE_HASH_KEY;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoInteractions;
diff --git a/proxy/src/test/java/google/registry/proxy/handler/WhoisQuotaHandlerTest.java b/proxy/src/test/java/google/registry/proxy/handler/WhoisQuotaHandlerTest.java
index 373022bbd..a29a000c4 100644
--- a/proxy/src/test/java/google/registry/proxy/handler/WhoisQuotaHandlerTest.java
+++ b/proxy/src/test/java/google/registry/proxy/handler/WhoisQuotaHandlerTest.java
@@ -17,7 +17,7 @@ package google.registry.proxy.handler;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.proxy.Protocol.PROTOCOL_KEY;
import static google.registry.proxy.handler.ProxyProtocolHandler.REMOTE_ADDRESS_KEY;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/proxy/src/test/java/google/registry/proxy/handler/WhoisServiceHandlerTest.java b/proxy/src/test/java/google/registry/proxy/handler/WhoisServiceHandlerTest.java
index a5aaf05e2..923dcfc95 100644
--- a/proxy/src/test/java/google/registry/proxy/handler/WhoisServiceHandlerTest.java
+++ b/proxy/src/test/java/google/registry/proxy/handler/WhoisServiceHandlerTest.java
@@ -18,7 +18,7 @@ import static com.google.common.truth.Truth.assertThat;
import static google.registry.proxy.TestUtils.makeWhoisHttpRequest;
import static google.registry.proxy.TestUtils.makeWhoisHttpResponse;
import static java.nio.charset.StandardCharsets.US_ASCII;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
diff --git a/proxy/src/test/java/google/registry/proxy/quota/QuotaConfigTest.java b/proxy/src/test/java/google/registry/proxy/quota/QuotaConfigTest.java
index 7038d3b8f..759dae78c 100644
--- a/proxy/src/test/java/google/registry/proxy/quota/QuotaConfigTest.java
+++ b/proxy/src/test/java/google/registry/proxy/quota/QuotaConfigTest.java
@@ -16,7 +16,7 @@ package google.registry.proxy.quota;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.util.ResourceUtils.readResourceUtf8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.proxy.ProxyConfig.Quota;
import org.joda.time.Duration;
diff --git a/util/build.gradle b/util/build.gradle
index 2751aee21..a1dbc796e 100644
--- a/util/build.gradle
+++ b/util/build.gradle
@@ -37,13 +37,12 @@ dependencies {
testCompile deps['com.google.appengine:appengine-api-stubs']
testCompile deps['com.google.guava:guava-testlib']
testCompile deps['com.google.truth:truth']
- testCompile deps['junit:junit']
testCompile deps['org.junit.jupiter:junit-jupiter-api']
testCompile deps['org.junit.jupiter:junit-jupiter-engine']
- testCompile deps['org.junit.vintage:junit-vintage-engine']
testCompile deps['org.hamcrest:hamcrest-all']
testCompile deps['org.hamcrest:hamcrest-core']
testCompile deps['org.mockito:mockito-core']
+ testCompile deps['org.mockito:mockito-junit-jupiter']
testCompile files("${rootDir}/third_party/objectify/v4_1/objectify-4.1.3.jar")
testCompile project(path: ':common', configuration: 'testing')
testRuntime deps['com.google.flogger:flogger-system-backend']
diff --git a/util/gradle/dependency-locks/testCompile.lockfile b/util/gradle/dependency-locks/testCompile.lockfile
index 612208410..7a29ca854 100644
--- a/util/gradle/dependency-locks/testCompile.lockfile
+++ b/util/gradle/dependency-locks/testCompile.lockfile
@@ -50,9 +50,9 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.mockito:mockito-core:3.3.3
+org.mockito:mockito-junit-jupiter:3.3.3
org.objenesis:objenesis:2.6
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/util/gradle/dependency-locks/testCompileClasspath.lockfile b/util/gradle/dependency-locks/testCompileClasspath.lockfile
index 612208410..7a29ca854 100644
--- a/util/gradle/dependency-locks/testCompileClasspath.lockfile
+++ b/util/gradle/dependency-locks/testCompileClasspath.lockfile
@@ -50,9 +50,9 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.mockito:mockito-core:3.3.3
+org.mockito:mockito-junit-jupiter:3.3.3
org.objenesis:objenesis:2.6
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/util/gradle/dependency-locks/testRuntime.lockfile b/util/gradle/dependency-locks/testRuntime.lockfile
index 1f717147c..4d77a4c6c 100644
--- a/util/gradle/dependency-locks/testRuntime.lockfile
+++ b/util/gradle/dependency-locks/testRuntime.lockfile
@@ -52,9 +52,9 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.mockito:mockito-core:3.3.3
+org.mockito:mockito-junit-jupiter:3.3.3
org.objenesis:objenesis:2.6
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/util/gradle/dependency-locks/testRuntimeClasspath.lockfile b/util/gradle/dependency-locks/testRuntimeClasspath.lockfile
index 1f717147c..4d77a4c6c 100644
--- a/util/gradle/dependency-locks/testRuntimeClasspath.lockfile
+++ b/util/gradle/dependency-locks/testRuntimeClasspath.lockfile
@@ -52,9 +52,9 @@ org.junit.jupiter:junit-jupiter-api:5.6.2
org.junit.jupiter:junit-jupiter-engine:5.6.2
org.junit.platform:junit-platform-commons:1.6.2
org.junit.platform:junit-platform-engine:1.6.2
-org.junit.vintage:junit-vintage-engine:5.6.2
org.junit:junit-bom:5.6.2
org.mockito:mockito-core:3.3.3
+org.mockito:mockito-junit-jupiter:3.3.3
org.objenesis:objenesis:2.6
org.opentest4j:opentest4j:1.2.0
org.yaml:snakeyaml:1.17
diff --git a/util/src/test/java/google/registry/util/AppEngineServiceUtilsImplTest.java b/util/src/test/java/google/registry/util/AppEngineServiceUtilsImplTest.java
index 8f662b5cb..a70b7b723 100644
--- a/util/src/test/java/google/registry/util/AppEngineServiceUtilsImplTest.java
+++ b/util/src/test/java/google/registry/util/AppEngineServiceUtilsImplTest.java
@@ -15,7 +15,7 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.ArgumentMatchers.isNull;
@@ -24,54 +24,51 @@ import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
import com.google.appengine.api.modules.ModulesService;
-import org.junit.Before;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.extension.ExtendWith;
import org.mockito.Mock;
-import org.mockito.junit.MockitoJUnit;
-import org.mockito.junit.MockitoRule;
+import org.mockito.junit.jupiter.MockitoExtension;
/** Unit tests for {@link AppEngineServiceUtilsImpl}. */
-@RunWith(JUnit4.class)
-public class AppEngineServiceUtilsImplTest {
-
- @Rule public final MockitoRule mocks = MockitoJUnit.rule();
+@ExtendWith(MockitoExtension.class)
+class AppEngineServiceUtilsImplTest {
@Mock private ModulesService modulesService;
private AppEngineServiceUtils appEngineServiceUtils;
- @Before
- public void before() {
+ @BeforeEach
+ void beforeEach() {
appEngineServiceUtils = new AppEngineServiceUtilsImpl(modulesService);
- when(modulesService.getVersionHostname(anyString(), isNull()))
- .thenReturn("1234.servicename.projectid.appspot.fake");
- when(modulesService.getVersionHostname(anyString(), eq("2345")))
- .thenReturn("2345.servicename.projectid.appspot.fake");
}
@Test
- public void test_getServiceHostname_doesntIncludeVersionId() {
+ void test_getServiceHostname_doesntIncludeVersionId() {
+ when(modulesService.getVersionHostname(anyString(), isNull()))
+ .thenReturn("1234.servicename.projectid.appspot.fake");
assertThat(appEngineServiceUtils.getServiceHostname("servicename"))
.isEqualTo("servicename.projectid.appspot.fake");
}
@Test
- public void test_getVersionHostname_doesIncludeVersionId() {
+ void test_getVersionHostname_doesIncludeVersionId() {
+ when(modulesService.getVersionHostname(anyString(), isNull()))
+ .thenReturn("1234.servicename.projectid.appspot.fake");
assertThat(appEngineServiceUtils.getCurrentVersionHostname("servicename"))
.isEqualTo("1234.servicename.projectid.appspot.fake");
}
@Test
- public void test_getVersionHostname_worksWithVersionId() {
+ void test_getVersionHostname_worksWithVersionId() {
+ when(modulesService.getVersionHostname(anyString(), eq("2345")))
+ .thenReturn("2345.servicename.projectid.appspot.fake");
assertThat(appEngineServiceUtils.getVersionHostname("servicename", "2345"))
.isEqualTo("2345.servicename.projectid.appspot.fake");
}
@Test
- public void test_getVersionHostname_throwsWhenVersionIdIsNull() {
+ void test_getVersionHostname_throwsWhenVersionIdIsNull() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -80,13 +77,13 @@ public class AppEngineServiceUtilsImplTest {
}
@Test
- public void test_setNumInstances_worksWithValidParameters() {
+ void test_setNumInstances_worksWithValidParameters() {
appEngineServiceUtils.setNumInstances("service", "version", 10L);
verify(modulesService, times(1)).setNumInstances("service", "version", 10L);
}
@Test
- public void test_setNumInstances_throwsWhenServiceIsNull() {
+ void test_setNumInstances_throwsWhenServiceIsNull() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -95,7 +92,7 @@ public class AppEngineServiceUtilsImplTest {
}
@Test
- public void test_setNumInstances_throwsWhenVersionIsNull() {
+ void test_setNumInstances_throwsWhenVersionIsNull() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -104,7 +101,7 @@ public class AppEngineServiceUtilsImplTest {
}
@Test
- public void test_setNumInstances_throwsWhenNumInstancesIsInvalid() {
+ void test_setNumInstances_throwsWhenNumInstancesIsInvalid() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -113,32 +110,32 @@ public class AppEngineServiceUtilsImplTest {
}
@Test
- public void test_convertToSingleSubdomain_doesNothingWithoutServiceOrHostname() {
+ void test_convertToSingleSubdomain_doesNothingWithoutServiceOrHostname() {
assertThat(appEngineServiceUtils.convertToSingleSubdomain("projectid.appspot.com"))
.isEqualTo("projectid.appspot.com");
}
@Test
- public void test_convertToSingleSubdomain_doesNothingWhenItCannotParseCorrectly() {
+ void test_convertToSingleSubdomain_doesNothingWhenItCannotParseCorrectly() {
assertThat(appEngineServiceUtils.convertToSingleSubdomain("garbage.notrealhost.example"))
.isEqualTo("garbage.notrealhost.example");
}
@Test
- public void test_convertToSingleSubdomain_convertsWithServiceName() {
+ void test_convertToSingleSubdomain_convertsWithServiceName() {
assertThat(appEngineServiceUtils.convertToSingleSubdomain("service.projectid.appspot.com"))
.isEqualTo("service-dot-projectid.appspot.com");
}
@Test
- public void test_convertToSingleSubdomain_convertsWithVersionAndServiceName() {
+ void test_convertToSingleSubdomain_convertsWithVersionAndServiceName() {
assertThat(
appEngineServiceUtils.convertToSingleSubdomain("version.service.projectid.appspot.com"))
.isEqualTo("version-dot-service-dot-projectid.appspot.com");
}
@Test
- public void test_convertToSingleSubdomain_convertsWithInstanceAndVersionAndServiceName() {
+ void test_convertToSingleSubdomain_convertsWithInstanceAndVersionAndServiceName() {
assertThat(
appEngineServiceUtils.convertToSingleSubdomain(
"instanceid.version.service.projectid.appspot.com"))
diff --git a/util/src/test/java/google/registry/util/CidrAddressBlockTest.java b/util/src/test/java/google/registry/util/CidrAddressBlockTest.java
index 978a06a90..0e9eb768b 100644
--- a/util/src/test/java/google/registry/util/CidrAddressBlockTest.java
+++ b/util/src/test/java/google/registry/util/CidrAddressBlockTest.java
@@ -14,8 +14,11 @@
package google.registry.util;
-import static org.junit.Assert.assertNotEquals;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertFalse;
+import static org.junit.jupiter.api.Assertions.assertNotEquals;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertTrue;
import com.google.common.collect.ImmutableMap;
import com.google.common.net.InetAddresses;
@@ -25,40 +28,42 @@ import java.net.InetAddress;
import java.util.Iterator;
import java.util.Map;
import java.util.NoSuchElementException;
-import junit.framework.TestCase;
+import org.junit.jupiter.api.Test;
-/**
- * Tests for {@link CidrAddressBlock}.
- *
- */
-public class CidrAddressBlockTest extends TestCase {
+/** Tests for {@link CidrAddressBlock}. */
+class CidrAddressBlockTest {
- public void testNulls() {
+ @Test
+ void testNulls() {
NullPointerTester tester = new NullPointerTester();
tester.testAllPublicStaticMethods(CidrAddressBlock.class);
tester.testAllPublicConstructors(CidrAddressBlock.class);
tester.testAllPublicInstanceMethods(new CidrAddressBlock("::/0"));
}
- public void testConstructorWithNetmask() {
+ @Test
+ void testConstructorWithNetmask() {
CidrAddressBlock b0 = new CidrAddressBlock("22.24.66.0/24");
assertEquals("22.24.66.0", b0.getIp());
assertEquals(24, b0.getNetmask());
}
- public void testConstructorPicksNetmask() {
+ @Test
+ void testConstructorPicksNetmask() {
CidrAddressBlock b0 = new CidrAddressBlock("64.132.1.2");
assertEquals(32, b0.getNetmask());
}
- public void testConstructorDoesntThrow() {
+ @Test
+ void testConstructorDoesntThrow() {
new CidrAddressBlock("64.132.0.0/16");
new CidrAddressBlock("128.142.217.0/24");
new CidrAddressBlock("35.213.0.0", 16);
new CidrAddressBlock("89.23.164.0", 24);
}
- public void testInetAddressConstructor() {
+ @Test
+ void testInetAddressConstructor() {
CidrAddressBlock b0 = new CidrAddressBlock(InetAddresses.forString("1.2.3.4"));
assertEquals(32, b0.getNetmask());
assertEquals("1.2.3.4", b0.getIp());
@@ -73,7 +78,8 @@ public class CidrAddressBlockTest extends TestCase {
assertEquals("5ffe:0:0:0:0:0:0:1", b1.getIp());
}
- public void testCornerCasesSucceed() {
+ @Test
+ void testCornerCasesSucceed() {
new CidrAddressBlock("0.0.0.0/32");
new CidrAddressBlock("255.255.255.255/32");
new CidrAddressBlock("255.255.255.254/31");
@@ -88,7 +94,8 @@ public class CidrAddressBlockTest extends TestCase {
new CidrAddressBlock("ffff:ffff:ffff:ffff:ffff:ffff:ffff:fffe/127");
}
- public void testFailure() {
+ @Test
+ void testFailure() {
assertConstructionFails("");
assertConstructionFails("0");
assertConstructionFails("1");
@@ -120,31 +127,31 @@ public class CidrAddressBlockTest extends TestCase {
assertConstructionFails("ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff/127");
}
- public void testTruncation() {
- ImmutableMap netblocks = new ImmutableMap.Builder()
- // IPv4
- .put("1.2.3.4/0", "0.0.0.0/0")
- .put("1.2.3.4/24", "1.2.3.0/24")
- .put("1.2.3.255/27", "1.2.3.224/27")
- .put("1.2.3.255/28", "1.2.3.240/28")
- // IPv6
- .put("2001:db8::1/0", "::/0")
- .put("2001:db8::1/16", "2001::/16")
- .put("2001:db8::1/21", "2001:800::/21")
- .put("2001:db8::1/22", "2001:c00::/22")
- .build();
+ @Test
+ void testTruncation() {
+ ImmutableMap netblocks =
+ new ImmutableMap.Builder()
+ // IPv4
+ .put("1.2.3.4/0", "0.0.0.0/0")
+ .put("1.2.3.4/24", "1.2.3.0/24")
+ .put("1.2.3.255/27", "1.2.3.224/27")
+ .put("1.2.3.255/28", "1.2.3.240/28")
+ // IPv6
+ .put("2001:db8::1/0", "::/0")
+ .put("2001:db8::1/16", "2001::/16")
+ .put("2001:db8::1/21", "2001:800::/21")
+ .put("2001:db8::1/22", "2001:c00::/22")
+ .build();
for (Map.Entry pair : netblocks.entrySet()) {
assertConstructionFails(pair.getKey());
+ assertEquals(new CidrAddressBlock(pair.getValue()), CidrAddressBlock.create(pair.getKey()));
assertEquals(
- new CidrAddressBlock(pair.getValue()),
- CidrAddressBlock.create(pair.getKey()));
- assertEquals(
- CidrAddressBlock.create(pair.getKey()),
- CidrAddressBlock.create(pair.getValue()));
+ CidrAddressBlock.create(pair.getKey()), CidrAddressBlock.create(pair.getValue()));
}
}
- public void testContains() {
+ @Test
+ void testContains() {
CidrAddressBlock b0 = CidrAddressBlock.create("172.24.255.0/24");
assertTrue(b0.contains(b0));
assertTrue(b0.contains(b0.getIp()));
@@ -226,19 +233,21 @@ public class CidrAddressBlockTest extends TestCase {
assertFalse(allIPv6.contains(allIPv4));
}
- public void testGetAllOnesAddress() {
+ @Test
+ void testGetAllOnesAddress() {
// ->
- ImmutableMap testCases = new ImmutableMap.Builder()
- .put("172.24.255.0/24", "172.24.255.255")
- .put("172.24.0.0/15", "172.25.255.255")
- .put("172.24.254.0/23", "172.24.255.255")
- .put("172.24.255.0/32", "172.24.255.0")
- .put("0.0.0.0/0", "255.255.255.255")
- .put("2001:db8::/48", "2001:db8::ffff:ffff:ffff:ffff:ffff")
- .put("2001:db8::/32", "2001:db8:ffff:ffff:ffff:ffff:ffff:ffff")
- .put("2001:db8::/128", "2001:db8::")
- .put("::/0", "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff")
- .build();
+ ImmutableMap testCases =
+ new ImmutableMap.Builder()
+ .put("172.24.255.0/24", "172.24.255.255")
+ .put("172.24.0.0/15", "172.25.255.255")
+ .put("172.24.254.0/23", "172.24.255.255")
+ .put("172.24.255.0/32", "172.24.255.0")
+ .put("0.0.0.0/0", "255.255.255.255")
+ .put("2001:db8::/48", "2001:db8::ffff:ffff:ffff:ffff:ffff")
+ .put("2001:db8::/32", "2001:db8:ffff:ffff:ffff:ffff:ffff:ffff")
+ .put("2001:db8::/128", "2001:db8::")
+ .put("::/0", "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff")
+ .build();
for (Map.Entry testCase : testCases.entrySet()) {
assertEquals(
@@ -247,7 +256,8 @@ public class CidrAddressBlockTest extends TestCase {
}
}
- public void testEqualsAndHashCode() {
+ @Test
+ void testEqualsAndHashCode() {
CidrAddressBlock b0 = new CidrAddressBlock("172.24.66.0/24");
CidrAddressBlock b1 = new CidrAddressBlock("172.24.66.0", 24);
CidrAddressBlock b2 = new CidrAddressBlock("172.24.0.0/16");
@@ -269,7 +279,8 @@ public class CidrAddressBlockTest extends TestCase {
assertNotEquals(b0, b3);
}
- public void testIterate() {
+ @Test
+ void testIterate() {
CidrAddressBlock b0 = new CidrAddressBlock("172.24.66.0/24");
int count = 0;
for (InetAddress addr : b0) {
@@ -293,7 +304,8 @@ public class CidrAddressBlockTest extends TestCase {
assertThrows(NoSuchElementException.class, i::next);
}
- public void testSerializability() {
+ @Test
+ void testSerializability() {
SerializableTester.reserializeAndAssert(new CidrAddressBlock("22.24.66.0/24"));
SerializableTester.reserializeAndAssert(new CidrAddressBlock("64.132.1.2"));
SerializableTester.reserializeAndAssert(
diff --git a/util/src/test/java/google/registry/util/CollectionUtilsTest.java b/util/src/test/java/google/registry/util/CollectionUtilsTest.java
index 414711d17..9edb44352 100644
--- a/util/src/test/java/google/registry/util/CollectionUtilsTest.java
+++ b/util/src/test/java/google/registry/util/CollectionUtilsTest.java
@@ -17,28 +17,25 @@ package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.util.CollectionUtils.nullToEmpty;
import static google.registry.util.CollectionUtils.partitionMap;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.HashMultimap;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import java.util.Map;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link CollectionUtils} */
-@RunWith(JUnit4.class)
-public class CollectionUtilsTest {
+class CollectionUtilsTest {
@Test
- public void testNullToEmptyMap_leavesNonNullAlone() {
+ void testNullToEmptyMap_leavesNonNullAlone() {
Map map = ImmutableMap.of("hello", 1);
assertThat(nullToEmpty(map)).isEqualTo(map);
}
@Test
- public void testNullToEmptyMap_convertsNullToEmptyMap() {
+ void testNullToEmptyMap_convertsNullToEmptyMap() {
Map map = null;
Map convertedMap = nullToEmpty(map);
assertThat(map).isNull();
@@ -47,7 +44,7 @@ public class CollectionUtilsTest {
}
@Test
- public void testPartitionMap() {
+ void testPartitionMap() {
Map map = ImmutableMap.of("ka", "va", "kb", "vb", "kc", "vc");
assertThat(partitionMap(map, 2)).containsExactlyElementsIn(ImmutableList.of(
ImmutableMap.of("ka", "va", "kb", "vb"),
@@ -55,22 +52,22 @@ public class CollectionUtilsTest {
}
@Test
- public void testPartitionMap_emptyInput() {
+ void testPartitionMap_emptyInput() {
assertThat(partitionMap(ImmutableMap.of(), 100)).isEmpty();
}
@Test
- public void testPartitionMap_negativePartitionSize() {
+ void testPartitionMap_negativePartitionSize() {
assertThrows(IllegalArgumentException.class, () -> partitionMap(ImmutableMap.of("A", "b"), -2));
}
@Test
- public void testPartitionMap_nullMap() {
+ void testPartitionMap_nullMap() {
assertThrows(NullPointerException.class, () -> partitionMap(null, 100));
}
@Test
- public void testDeadCodeWeDontWantToDelete() {
+ void testDeadCodeWeDontWantToDelete() {
CollectionUtils.nullToEmpty(HashMultimap.create());
}
}
diff --git a/util/src/test/java/google/registry/util/ComparingInvocationHandlerTest.java b/util/src/test/java/google/registry/util/ComparingInvocationHandlerTest.java
index 4a8e63914..e7caa57bd 100644
--- a/util/src/test/java/google/registry/util/ComparingInvocationHandlerTest.java
+++ b/util/src/test/java/google/registry/util/ComparingInvocationHandlerTest.java
@@ -15,23 +15,20 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
import java.lang.reflect.Method;
import java.util.ArrayList;
import javax.annotation.Nullable;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link ComparingInvocationHandler}. */
-@RunWith(JUnit4.class)
-public class ComparingInvocationHandlerTest {
+class ComparingInvocationHandlerTest {
- static class Dummy {}
+ private static class Dummy {}
interface MyInterface {
String func(int a, String b);
@@ -51,7 +48,7 @@ public class ComparingInvocationHandlerTest {
}
}
- static final ArrayList log = new ArrayList<>();
+ private static final ArrayList log = new ArrayList<>();
static final class MyInterfaceComparingInvocationHandler
extends ComparingInvocationHandler {
@@ -112,14 +109,14 @@ public class ComparingInvocationHandlerTest {
private final MyInterface mySecondMock = mock(MyInterface.class);
private MyInterfaceComparingInvocationHandler invocationHandler;
- @Before
- public void setUp() {
+ @BeforeEach
+ void beforeEach() {
log.clear();
invocationHandler = new MyInterfaceComparingInvocationHandler(myActualMock, mySecondMock);
}
@Test
- public void test_actualThrows_logDifference() {
+ void test_actualThrows_logDifference() {
MyInterface comparator = invocationHandler.makeProxy();
MyException myException = new MyException("message");
when(myActualMock.func(3, "str")).thenThrow(myException);
@@ -134,7 +131,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_secondThrows_logDifference() {
+ void test_secondThrows_logDifference() {
MyInterface comparator = invocationHandler.makeProxy();
MyOtherException myOtherException = new MyOtherException("message");
when(myActualMock.func(3, "str")).thenReturn(ACTUAL_RESULT);
@@ -150,7 +147,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_bothThrowEqual_noLog() {
+ void test_bothThrowEqual_noLog() {
MyInterface comparator = invocationHandler.setExeptionsEquals(true).makeProxy();
MyException myException = new MyException("actual message");
MyOtherException myOtherException = new MyOtherException("second message");
@@ -162,7 +159,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_bothThrowDifferent_logDifference() {
+ void test_bothThrowDifferent_logDifference() {
MyInterface comparator = invocationHandler.setExeptionsEquals(false).makeProxy();
MyException myException = new MyException("actual message");
MyOtherException myOtherException = new MyOtherException("second message");
@@ -179,7 +176,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_bothReturnSame_noLog() {
+ void test_bothReturnSame_noLog() {
MyInterface comparator = invocationHandler.makeProxy();
when(myActualMock.func(3, "str")).thenReturn(ACTUAL_RESULT);
when(mySecondMock.func(3, "str")).thenReturn(ACTUAL_RESULT);
@@ -190,7 +187,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_bothReturnDifferent_logDifference() {
+ void test_bothReturnDifferent_logDifference() {
MyInterface comparator = invocationHandler.makeProxy();
when(myActualMock.func(3, "str")).thenReturn(ACTUAL_RESULT);
when(mySecondMock.func(3, "str")).thenReturn(SECOND_RESULT);
@@ -202,7 +199,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_usesOverriddenMethods_noDifference() {
+ void test_usesOverriddenMethods_noDifference() {
MyInterface comparator = invocationHandler.setDummyEquals(true).makeProxy();
when(myActualMock.func()).thenReturn(new Dummy());
when(mySecondMock.func()).thenReturn(new Dummy());
@@ -213,7 +210,7 @@ public class ComparingInvocationHandlerTest {
}
@Test
- public void test_usesOverriddenMethods_logDifference() {
+ void test_usesOverriddenMethods_logDifference() {
MyInterface comparator = invocationHandler.setDummyEquals(false).makeProxy();
when(myActualMock.func()).thenReturn(new Dummy());
when(mySecondMock.func()).thenReturn(new Dummy());
diff --git a/util/src/test/java/google/registry/util/DateTimeUtilsTest.java b/util/src/test/java/google/registry/util/DateTimeUtilsTest.java
index 06e64b5dd..04719e3db 100644
--- a/util/src/test/java/google/registry/util/DateTimeUtilsTest.java
+++ b/util/src/test/java/google/registry/util/DateTimeUtilsTest.java
@@ -25,57 +25,54 @@ import static google.registry.util.DateTimeUtils.leapSafeAddYears;
import static google.registry.util.DateTimeUtils.leapSafeSubtractYears;
import static google.registry.util.DateTimeUtils.toJodaDateTime;
import static google.registry.util.DateTimeUtils.toZonedDateTime;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import java.time.ZonedDateTime;
import org.joda.time.DateTime;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link DateTimeUtils}. */
-@RunWith(JUnit4.class)
-public class DateTimeUtilsTest {
+class DateTimeUtilsTest {
- ImmutableList sampleDates = ImmutableList.of(
- START_OF_TIME, START_OF_TIME.plusDays(1), END_OF_TIME, END_OF_TIME);
+ private ImmutableList sampleDates =
+ ImmutableList.of(START_OF_TIME, START_OF_TIME.plusDays(1), END_OF_TIME, END_OF_TIME);
@Test
- public void testSuccess_earliestOf() {
+ void testSuccess_earliestOf() {
assertThat(earliestOf(START_OF_TIME, END_OF_TIME)).isEqualTo(START_OF_TIME);
assertThat(earliestOf(sampleDates)).isEqualTo(START_OF_TIME);
}
@Test
- public void testSuccess_latestOf() {
+ void testSuccess_latestOf() {
assertThat(latestOf(START_OF_TIME, END_OF_TIME)).isEqualTo(END_OF_TIME);
assertThat(latestOf(sampleDates)).isEqualTo(END_OF_TIME);
}
@Test
- public void testSuccess_isBeforeOrAt() {
+ void testSuccess_isBeforeOrAt() {
assertThat(isBeforeOrAt(START_OF_TIME, START_OF_TIME.plusDays(1))).isTrue();
assertThat(isBeforeOrAt(START_OF_TIME, START_OF_TIME)).isTrue();
assertThat(isBeforeOrAt(START_OF_TIME.plusDays(1), START_OF_TIME)).isFalse();
}
@Test
- public void testSuccess_isAtOrAfter() {
+ void testSuccess_isAtOrAfter() {
assertThat(isAtOrAfter(START_OF_TIME, START_OF_TIME.plusDays(1))).isFalse();
assertThat(isAtOrAfter(START_OF_TIME, START_OF_TIME)).isTrue();
assertThat(isAtOrAfter(START_OF_TIME.plusDays(1), START_OF_TIME)).isTrue();
}
@Test
- public void testSuccess_leapSafeAddYears() {
+ void testSuccess_leapSafeAddYears() {
DateTime startDate = DateTime.parse("2012-02-29T00:00:00Z");
assertThat(startDate.plusYears(4)).isEqualTo(DateTime.parse("2016-02-29T00:00:00Z"));
assertThat(leapSafeAddYears(startDate, 4)).isEqualTo(DateTime.parse("2016-02-28T00:00:00Z"));
}
@Test
- public void testSuccess_leapSafeSubtractYears() {
+ void testSuccess_leapSafeSubtractYears() {
DateTime startDate = DateTime.parse("2012-02-29T00:00:00Z");
assertThat(startDate.minusYears(4)).isEqualTo(DateTime.parse("2008-02-29T00:00:00Z"));
assertThat(leapSafeSubtractYears(startDate, 4))
@@ -83,58 +80,58 @@ public class DateTimeUtilsTest {
}
@Test
- public void testSuccess_leapSafeSubtractYears_zeroYears() {
+ void testSuccess_leapSafeSubtractYears_zeroYears() {
DateTime leapDay = DateTime.parse("2012-02-29T00:00:00Z");
assertThat(leapDay.minusYears(0)).isEqualTo(leapDay);
}
@Test
- public void testFailure_earliestOfEmpty() {
+ void testFailure_earliestOfEmpty() {
assertThrows(IllegalArgumentException.class, () -> earliestOf(ImmutableList.of()));
}
@Test
- public void testFailure_latestOfEmpty() {
+ void testFailure_latestOfEmpty() {
assertThrows(IllegalArgumentException.class, () -> earliestOf(ImmutableList.of()));
}
@Test
- public void testSuccess_toZonedDateTime_preservesTimeZone() {
+ void testSuccess_toZonedDateTime_preservesTimeZone() {
DateTime dateTime = DateTime.parse("2019-09-06T10:59:36.283-07:00"); // PDT
ZonedDateTime zonedDateTime = toZonedDateTime(dateTime);
assertThat(zonedDateTime.toString()).isEqualTo("2019-09-06T10:59:36.283-07:00"); // still PDT
}
@Test
- public void testSuccess_toZonedDateTime_fromStringZulu() {
+ void testSuccess_toZonedDateTime_fromStringZulu() {
DateTime dateTime = DateTime.parse("2015-10-13T11:22:33.168Z");
ZonedDateTime zonedDateTime = toZonedDateTime(dateTime);
assertThat(zonedDateTime.toString()).isEqualTo("2015-10-13T11:22:33.168Z");
}
@Test
- public void testSuccess_toZonedDateTime_leapYear() {
+ void testSuccess_toZonedDateTime_leapYear() {
DateTime dateTime = DateTime.parse("2016-02-29T11:22:33.168Z");
ZonedDateTime zonedDateTime = toZonedDateTime(dateTime);
assertThat(zonedDateTime.toString()).isEqualTo("2016-02-29T11:22:33.168Z");
}
@Test
- public void testSuccess_toJodaDateTime_preservesTimeZone() {
+ void testSuccess_toJodaDateTime_preservesTimeZone() {
ZonedDateTime zonedDateTime = ZonedDateTime.parse("2019-09-06T10:59:36.283-07:00"); // PDT
DateTime dateTime = toJodaDateTime(zonedDateTime);
assertThat(dateTime.toString()).isEqualTo("2019-09-06T10:59:36.283-07:00"); // still PDT
}
@Test
- public void testSuccess_toJodaDateTime_fromStringZulu() {
+ void testSuccess_toJodaDateTime_fromStringZulu() {
ZonedDateTime zonedDateTime = ZonedDateTime.parse("2015-10-13T11:22:33.168Z");
DateTime dateTime = toJodaDateTime(zonedDateTime);
assertThat(dateTime.toString()).isEqualTo("2015-10-13T11:22:33.168Z");
}
@Test
- public void testSuccess_toJodaDateTime_leapYear() {
+ void testSuccess_toJodaDateTime_leapYear() {
ZonedDateTime zonedDateTime = ZonedDateTime.parse("2016-02-29T11:22:33.168Z");
DateTime dateTime = toJodaDateTime(zonedDateTime);
assertThat(dateTime.toString()).isEqualTo("2016-02-29T11:22:33.168Z");
diff --git a/util/src/test/java/google/registry/util/DiffUtilsTest.java b/util/src/test/java/google/registry/util/DiffUtilsTest.java
index 50f7eb383..877a839fa 100644
--- a/util/src/test/java/google/registry/util/DiffUtilsTest.java
+++ b/util/src/test/java/google/registry/util/DiffUtilsTest.java
@@ -21,47 +21,43 @@ import static google.registry.util.DiffUtils.prettyPrintSetDiff;
import com.google.common.collect.ImmutableSet;
import java.util.HashMap;
import java.util.Map;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link DiffUtils} */
-@RunWith(JUnit4.class)
-public class DiffUtilsTest {
+class DiffUtilsTest {
@Test
- public void test_prettyPrintSetDiff_emptySets() {
+ void test_prettyPrintSetDiff_emptySets() {
assertThat(prettyPrintSetDiff(ImmutableSet.of(), ImmutableSet.of()))
.isEqualTo("NO DIFFERENCES");
}
@Test
- public void test_prettyPrintSetDiff_noDifferences() {
+ void test_prettyPrintSetDiff_noDifferences() {
assertThat(prettyPrintSetDiff(ImmutableSet.of("c", "x", "m"), ImmutableSet.of("m", "x", "c")))
.isEqualTo("NO DIFFERENCES");
}
@Test
- public void test_prettyPrintSetDiff_addedElements() {
+ void test_prettyPrintSetDiff_addedElements() {
assertThat(prettyPrintSetDiff(ImmutableSet.of("z"), ImmutableSet.of("a", "b", "z")))
.isEqualTo("\n ADDED: [a, b]\n FINAL CONTENTS: [a, b, z]");
}
@Test
- public void test_prettyPrintSetDiff_removedElements() {
+ void test_prettyPrintSetDiff_removedElements() {
assertThat(prettyPrintSetDiff(ImmutableSet.of("x", "y", "z"), ImmutableSet.of("y")))
.isEqualTo("\n REMOVED: [x, z]\n FINAL CONTENTS: [y]");
}
@Test
- public void test_prettyPrintSetDiff_addedAndRemovedElements() {
- assertThat(prettyPrintSetDiff(
- ImmutableSet.of("a", "b", "c"), ImmutableSet.of("a", "y", "z")))
+ void test_prettyPrintSetDiff_addedAndRemovedElements() {
+ assertThat(prettyPrintSetDiff(ImmutableSet.of("a", "b", "c"), ImmutableSet.of("a", "y", "z")))
.isEqualTo("\n ADDED: [y, z]\n REMOVED: [b, c]\n FINAL CONTENTS: [a, y, z]");
}
@Test
- public void test_emptyToNullCollection_doesntDisplay() {
+ void test_emptyToNullCollection_doesntDisplay() {
Map mapA = new HashMap<>();
mapA.put("a", "jim");
mapA.put("b", null);
@@ -73,27 +69,27 @@ public class DiffUtilsTest {
}
@Test
- public void test_prettyPrintSetDiff_addedAndRemovedElements_objects() {
+ void test_prettyPrintSetDiff_addedAndRemovedElements_objects() {
DummyObject a = DummyObject.create("a");
DummyObject b = DummyObject.create("b");
DummyObject c = DummyObject.create("c");
- assertThat(prettyPrintSetDiff(
- ImmutableSet.of(a, b), ImmutableSet.of(a, c)))
- .isEqualTo("\n"
- + " ADDED:\n"
- + " {c}\n"
- + " REMOVED:\n"
- + " {b}\n"
- + " FINAL CONTENTS:\n"
- + " {a},\n"
- + " {c}");
+ assertThat(prettyPrintSetDiff(ImmutableSet.of(a, b), ImmutableSet.of(a, c)))
+ .isEqualTo(
+ "\n"
+ + " ADDED:\n"
+ + " {c}\n"
+ + " REMOVED:\n"
+ + " {b}\n"
+ + " FINAL CONTENTS:\n"
+ + " {a},\n"
+ + " {c}");
}
private static class DummyObject {
- public String id;
+ String id;
- public static DummyObject create(String id) {
+ static DummyObject create(String id) {
DummyObject instance = new DummyObject();
instance.id = id;
return instance;
diff --git a/util/src/test/java/google/registry/util/DomainNameUtilsTest.java b/util/src/test/java/google/registry/util/DomainNameUtilsTest.java
index 497b1d5ff..d562bccb1 100644
--- a/util/src/test/java/google/registry/util/DomainNameUtilsTest.java
+++ b/util/src/test/java/google/registry/util/DomainNameUtilsTest.java
@@ -17,17 +17,15 @@ package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.util.DomainNameUtils.canonicalizeDomainName;
import static google.registry.util.DomainNameUtils.getSecondLevelDomain;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link DomainNameUtils}. */
-@RunWith(JUnit4.class)
-public class DomainNameUtilsTest {
+class DomainNameUtilsTest {
+
@Test
- public void testCanonicalizeDomainName() {
+ void testCanonicalizeDomainName() {
assertThat(canonicalizeDomainName("foo")).isEqualTo("foo");
assertThat(canonicalizeDomainName("FOO")).isEqualTo("foo");
assertThat(canonicalizeDomainName("foo.tld")).isEqualTo("foo.tld");
@@ -41,12 +39,12 @@ public class DomainNameUtilsTest {
}
@Test
- public void testCanonicalizeDomainName_acePrefixUnicodeChars() {
+ void testCanonicalizeDomainName_acePrefixUnicodeChars() {
assertThrows(IllegalArgumentException.class, () -> canonicalizeDomainName("xn--みんな"));
}
@Test
- public void testGetSecondLevelDomain_returnsProperDomain() {
+ void testGetSecondLevelDomain_returnsProperDomain() {
assertThat(getSecondLevelDomain("foo.bar", "bar")).isEqualTo("foo.bar");
assertThat(getSecondLevelDomain("ns1.foo.bar", "bar")).isEqualTo("foo.bar");
assertThat(getSecondLevelDomain("ns1.abc.foo.bar", "bar")).isEqualTo("foo.bar");
@@ -54,20 +52,18 @@ public class DomainNameUtilsTest {
}
@Test
- public void testGetSecondLevelDomain_insufficientDomainNameDepth() {
+ void testGetSecondLevelDomain_insufficientDomainNameDepth() {
IllegalArgumentException thrown =
- assertThrows(
- IllegalArgumentException.class, () -> getSecondLevelDomain("bar", "bar"));
+ assertThrows(IllegalArgumentException.class, () -> getSecondLevelDomain("bar", "bar"));
assertThat(thrown)
.hasMessageThat()
.isEqualTo("hostName must be at least one level below the tld");
}
@Test
- public void testGetSecondLevelDomain_domainNotUnderTld() {
+ void testGetSecondLevelDomain_domainNotUnderTld() {
IllegalArgumentException thrown =
- assertThrows(
- IllegalArgumentException.class, () -> getSecondLevelDomain("foo.bar", "abc"));
+ assertThrows(IllegalArgumentException.class, () -> getSecondLevelDomain("foo.bar", "abc"));
assertThat(thrown).hasMessageThat().isEqualTo("hostName must be under the tld");
}
}
diff --git a/util/src/test/java/google/registry/util/HexDumperTest.java b/util/src/test/java/google/registry/util/HexDumperTest.java
index 917fe35db..683489e11 100644
--- a/util/src/test/java/google/registry/util/HexDumperTest.java
+++ b/util/src/test/java/google/registry/util/HexDumperTest.java
@@ -16,19 +16,16 @@ package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import java.io.StringWriter;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link HexDumper}. */
-@RunWith(JUnit4.class)
-public class HexDumperTest {
+class HexDumperTest {
@Test
- public void testEmpty() {
+ void testEmpty() {
String input = "";
String output = "[0 bytes total]\n";
assertThat(input).isEmpty();
@@ -36,78 +33,84 @@ public class HexDumperTest {
}
@Test
- public void testOneLine() {
+ void testOneLine() {
String input = "hello world";
- String output = "[11 bytes total]\n"
- + "00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 hello world \n";
+ String output =
+ "[11 bytes total]\n"
+ + "00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 hello world \n";
assertThat(input).hasLength(11);
assertThat(HexDumper.dumpHex(input.getBytes(UTF_8))).isEqualTo(output);
}
@Test
- public void testMultiLine() {
- String input = ""
- + "\n"
- + "Maids heard the goblins cry:\n"
- + "\"Come buy our orchard fruits,\n"
- + "\"Come buy, come buy:\n";
- String output = "[81 bytes total]\n"
- + "00000000 0a 4d 61 69 64 73 20 68 65 61 72 64 20 74 68 65 .Maids heard the\n"
- + "00000016 20 67 6f 62 6c 69 6e 73 20 63 72 79 3a 0a 22 43 goblins cry:.\"C\n"
- + "00000032 6f 6d 65 20 62 75 79 20 6f 75 72 20 6f 72 63 68 ome buy our orch\n"
- + "00000048 61 72 64 20 66 72 75 69 74 73 2c 0a 22 43 6f 6d ard fruits,.\"Com\n"
- + "00000064 65 20 62 75 79 2c 20 63 6f 6d 65 20 62 75 79 3a e buy, come buy:\n"
- + "00000080 0a . \n";
+ void testMultiLine() {
+ String input =
+ ""
+ + "\n"
+ + "Maids heard the goblins cry:\n"
+ + "\"Come buy our orchard fruits,\n"
+ + "\"Come buy, come buy:\n";
+ String output =
+ "[81 bytes total]\n"
+ + "00000000 0a 4d 61 69 64 73 20 68 65 61 72 64 20 74 68 65 .Maids heard the\n"
+ + "00000016 20 67 6f 62 6c 69 6e 73 20 63 72 79 3a 0a 22 43 goblins cry:.\"C\n"
+ + "00000032 6f 6d 65 20 62 75 79 20 6f 75 72 20 6f 72 63 68 ome buy our orch\n"
+ + "00000048 61 72 64 20 66 72 75 69 74 73 2c 0a 22 43 6f 6d ard fruits,.\"Com\n"
+ + "00000064 65 20 62 75 79 2c 20 63 6f 6d 65 20 62 75 79 3a e buy, come buy:\n"
+ + "00000080 0a . \n";
assertThat(input).hasLength(81);
assertThat(HexDumper.dumpHex(input.getBytes(UTF_8))).isEqualTo(output);
}
@Test
- public void testFullLine() {
+ void testFullLine() {
String input = "hello worldddddd";
- String output = "[16 bytes total]\n"
- + "00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 64 64 64 64 64 hello worldddddd\n";
+ String output =
+ "[16 bytes total]\n"
+ + "00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 64 64 64 64 64 hello worldddddd\n";
assertThat(input).hasLength(16);
assertThat(HexDumper.dumpHex(input.getBytes(UTF_8))).isEqualTo(output);
}
@Test
- public void testUnicode() {
+ void testUnicode() {
String input = "(◕‿◕)";
- String output = "[11 bytes total]\n"
- + "00000000 28 e2 97 95 e2 80 bf e2 97 95 29 (.........) \n";
+ String output =
+ "[11 bytes total]\n"
+ + "00000000 28 e2 97 95 e2 80 bf e2 97 95 29 (.........) \n";
assertThat(input).hasLength(5);
assertThat(HexDumper.dumpHex(input.getBytes(UTF_8))).isEqualTo(output);
}
@Test
- public void testRainbow() {
+ void testRainbow() {
byte[] input = new byte[256];
for (int n = 0; n < 256; ++n) {
input[n] = (byte) n;
}
- String output = "[256 bytes total]\n"
- + "00000000 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f ................\n"
- + "00000016 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f ................\n"
- + "00000032 20 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f !\"#$%&'()*+,-./\n"
- + "00000048 30 31 32 33 34 35 36 37 38 39 3a 3b 3c 3d 3e 3f 0123456789:;<=>?\n"
- + "00000064 40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d 4e 4f @ABCDEFGHIJKLMNO\n"
- + "00000080 50 51 52 53 54 55 56 57 58 59 5a 5b 5c 5d 5e 5f PQRSTUVWXYZ[\\]^_\n"
- + "00000096 60 61 62 63 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f `abcdefghijklmno\n"
- + "00000112 70 71 72 73 74 75 76 77 78 79 7a 7b 7c 7d 7e 7f pqrstuvwxyz{|}~.\n"
- + "00000128 80 81 82 83 84 85 86 87 88 89 8a 8b 8c 8d 8e 8f ................\n"
- + "00000144 90 91 92 93 94 95 96 97 98 99 9a 9b 9c 9d 9e 9f ................\n"
- + "00000160 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 aa ab ac ad ae af ................\n"
- + "00000176 b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 ba bb bc bd be bf ................\n"
- + "00000192 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 ca cb cc cd ce cf ................\n"
- + "00000208 d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 da db dc dd de df ................\n"
- + "00000224 e0 e1 e2 e3 e4 e5 e6 e7 e8 e9 ea eb ec ed ee ef ................\n"
- + "00000240 f0 f1 f2 f3 f4 f5 f6 f7 f8 f9 fa fb fc fd fe ff ................\n";
+ String output =
+ "[256 bytes total]\n"
+ + "00000000 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f ................\n"
+ + "00000016 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f ................\n"
+ + "00000032 20 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f !\"#$%&'()*+,-./\n"
+ + "00000048 30 31 32 33 34 35 36 37 38 39 3a 3b 3c 3d 3e 3f 0123456789:;<=>?\n"
+ + "00000064 40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d 4e 4f @ABCDEFGHIJKLMNO\n"
+ + "00000080 50 51 52 53 54 55 56 57 58 59 5a 5b 5c 5d 5e 5f PQRSTUVWXYZ[\\]^_\n"
+ + "00000096 60 61 62 63 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f `abcdefghijklmno\n"
+ + "00000112 70 71 72 73 74 75 76 77 78 79 7a 7b 7c 7d 7e 7f pqrstuvwxyz{|}~.\n"
+ + "00000128 80 81 82 83 84 85 86 87 88 89 8a 8b 8c 8d 8e 8f ................\n"
+ + "00000144 90 91 92 93 94 95 96 97 98 99 9a 9b 9c 9d 9e 9f ................\n"
+ + "00000160 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 aa ab ac ad ae af ................\n"
+ + "00000176 b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 ba bb bc bd be bf ................\n"
+ + "00000192 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 ca cb cc cd ce cf ................\n"
+ + "00000208 d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 da db dc dd de df ................\n"
+ + "00000224 e0 e1 e2 e3 e4 e5 e6 e7 e8 e9 ea eb ec ed ee ef ................\n"
+ + "00000240 f0 f1 f2 f3 f4 f5 f6 f7 f8 f9 fa fb fc fd fe ff ................\n";
assertThat(HexDumper.dumpHex(input)).isEqualTo(output);
}
@Test
- public void testLineBuffering() throws Exception {
+ void testLineBuffering() throws Exception {
// Assume that we have some data that's N bytes long.
byte[] data = "Sweet to tongue and sound to eye; Come buy, come buy.".getBytes(UTF_8);
// And a streaming HexDumper that displays N+1 characters per row.
@@ -134,7 +137,7 @@ public class HexDumperTest {
}
@Test
- public void testFlush() throws Exception {
+ void testFlush() throws Exception {
try (StringWriter out = new StringWriter();
HexDumper dumper = new HexDumper(out)) {
dumper.write("hello ".getBytes(UTF_8));
@@ -146,56 +149,58 @@ public class HexDumperTest {
dumper.flush();
assertThat(out.toString()).isEqualTo("00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 ");
dumper.close();
- assertThat(out.toString()).isEqualTo(
- "00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 hello world \n");
+ assertThat(out.toString())
+ .isEqualTo(
+ "00000000 68 65 6c 6c 6f 20 77 6f 72 6c 64 hello world \n");
}
}
@Test
- public void testPerLineIsOne() {
+ void testPerLineIsOne() {
String input = "hello";
- String output = "[5 bytes total]\n"
- + "00000000 68 h\n"
- + "00000001 65 e\n"
- + "00000002 6c l\n"
- + "00000003 6c l\n"
- + "00000004 6f o\n";
+ String output =
+ "[5 bytes total]\n"
+ + "00000000 68 h\n"
+ + "00000001 65 e\n"
+ + "00000002 6c l\n"
+ + "00000003 6c l\n"
+ + "00000004 6f o\n";
assertThat(HexDumper.dumpHex(input.getBytes(UTF_8), 1, 0)).isEqualTo(output);
}
@Test
- public void testBadArgumentPerLineZero() {
+ void testBadArgumentPerLineZero() {
HexDumper.dumpHex(new byte[1], 1, 0);
assertThrows(IllegalArgumentException.class, () -> HexDumper.dumpHex(new byte[1], 0, 0));
}
@Test
- public void testBadArgumentPerLineNegative() {
+ void testBadArgumentPerLineNegative() {
HexDumper.dumpHex(new byte[1], 1, 0);
assertThrows(IllegalArgumentException.class, () -> HexDumper.dumpHex(new byte[1], -1, 0));
}
@Test
- public void testBadArgumentPerGroupNegative() {
+ void testBadArgumentPerGroupNegative() {
HexDumper.dumpHex(new byte[1], 1, 0);
assertThrows(IllegalArgumentException.class, () -> HexDumper.dumpHex(new byte[1], 1, -1));
}
@Test
- public void testBadArgumentPerGroupGreaterThanOrEqualToPerLine() {
+ void testBadArgumentPerGroupGreaterThanOrEqualToPerLine() {
HexDumper.dumpHex(new byte[1], 1, 0);
HexDumper.dumpHex(new byte[1], 2, 1);
assertThrows(IllegalArgumentException.class, () -> HexDumper.dumpHex(new byte[1], 1, 1));
}
@Test
- public void testBadArgumentBytesIsNull() {
+ void testBadArgumentBytesIsNull() {
HexDumper.dumpHex(new byte[1]);
assertThrows(NullPointerException.class, () -> HexDumper.dumpHex(null));
}
@Test
- public void testMultiClose() throws Exception {
+ void testMultiClose() throws Exception {
try (StringWriter out = new StringWriter();
HexDumper dumper = new HexDumper(out)) {
dumper.close();
diff --git a/util/src/test/java/google/registry/util/PasswordUtilsTest.java b/util/src/test/java/google/registry/util/PasswordUtilsTest.java
index 0c523945d..b4d5f1068 100644
--- a/util/src/test/java/google/registry/util/PasswordUtilsTest.java
+++ b/util/src/test/java/google/registry/util/PasswordUtilsTest.java
@@ -20,16 +20,13 @@ import static google.registry.util.PasswordUtils.SALT_SUPPLIER;
import static google.registry.util.PasswordUtils.hashPassword;
import java.util.Arrays;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link google.registry.util.PasswordUtils}. */
-@RunWith(JUnit4.class)
-public final class PasswordUtilsTest {
+final class PasswordUtilsTest {
@Test
- public void testDifferentSalts() {
+ void testDifferentSalts() {
byte[] first = SALT_SUPPLIER.get();
byte[] second = SALT_SUPPLIER.get();
assertThat(first.length).isEqualTo(32);
@@ -38,7 +35,7 @@ public final class PasswordUtilsTest {
}
@Test
- public void testHash() {
+ void testHash() {
String salt = base64().encode(SALT_SUPPLIER.get());
String password = "mySuperSecurePassword";
String hashedPassword = hashPassword(password, salt);
diff --git a/util/src/test/java/google/registry/util/PosixTarHeaderSystemTest.java b/util/src/test/java/google/registry/util/PosixTarHeaderSystemTest.java
deleted file mode 100644
index 0c3178338..000000000
--- a/util/src/test/java/google/registry/util/PosixTarHeaderSystemTest.java
+++ /dev/null
@@ -1,263 +0,0 @@
-// Copyright 2017 The Nomulus Authors. All Rights Reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package google.registry.util;
-
-import static com.google.common.truth.Truth.assertThat;
-import static com.google.common.truth.Truth.assertWithMessage;
-import static google.registry.testing.SystemInfo.hasCommand;
-import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assume.assumeTrue;
-
-import com.google.common.collect.ImmutableMap;
-import com.google.common.collect.ImmutableSet;
-import com.google.common.io.CharStreams;
-import com.google.common.io.Files;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.InputStreamReader;
-import java.util.Map;
-import java.util.Random;
-import java.util.Set;
-import org.junit.Ignore;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.rules.TemporaryFolder;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
-
-/** System integration tests for {@link PosixTarHeader}. */
-@RunWith(JUnit4.class)
-public class PosixTarHeaderSystemTest {
-
- @Rule
- public final TemporaryFolder folder = new TemporaryFolder();
-
- @Test
- @Ignore
- public void testCreateSingleFileArchive() throws Exception {
- assumeTrue(hasCommand("tar"));
-
- // We have some data (in memory) that we'll call hello.txt.
- String fileName = "hello.txt";
- byte[] fileData = "hello world\n".getBytes(UTF_8);
-
- // We're going to put it in a new tar archive (on the filesystem) named hello.tar.
- String tarName = "hello.tar";
- File tarFile = folder.newFile(tarName);
- try (FileOutputStream output = new FileOutputStream(tarFile)) {
- output.write(new PosixTarHeader.Builder()
- .setName(fileName)
- .setSize(fileData.length)
- .build()
- .getBytes());
- output.write(fileData);
- output.write(new byte[512 - fileData.length % 512]); // Align with 512-byte block size.
- output.write(new byte[1024]); // Bunch of null bytes to indicate end of archive.
- }
- assertThat(tarFile.length() % 512).isEqualTo(0);
- assertThat(tarFile.length() / 512).isEqualTo(2 + 2);
-
- // Now we run the system's tar command to extract our file.
- String[] cmd = {"tar", "-xf", tarName};
- String[] env = {"PATH=" + System.getenv("PATH")};
- File cwd = folder.getRoot();
- Process pid = Runtime.getRuntime().exec(cmd, env, cwd);
- String err = CharStreams.toString(new InputStreamReader(pid.getErrorStream(), UTF_8));
- assertThat(pid.waitFor()).isEqualTo(0);
- assertThat(err.trim()).isEmpty();
-
- // And verify that hello.txt came out.
- File dataFile = new File(cwd, fileName);
- assertThat(dataFile.exists()).isTrue();
- assertThat(dataFile.isFile()).isTrue();
- assertThat(Files.asByteSource(dataFile).read()).isEqualTo(fileData);
-
- // And that nothing else came out.
- Set expectedFiles = ImmutableSet.of(tarName, fileName);
- assertThat(ImmutableSet.copyOf(folder.getRoot().list())).isEqualTo(expectedFiles);
- }
-
- @Test
- @Ignore
- public void testCreateMultiFileArchive() throws Exception {
- assumeTrue(hasCommand("tar"));
-
- Map files = ImmutableMap.of(
- "one.txt", ""
- + "There is data on line one\n"
- + "and on line two\n"
- + "and on line three\n",
- "two.txt", ""
- + "There is even more data\n"
- + "in this second file\n"
- + "with its own three lines\n",
- "subdir/three.txt", ""
- + "More data\n"
- + "but only two lines\n");
-
- String tarName = "hello.tar";
- File tarFile = folder.newFile(tarName);
- try (FileOutputStream output = new FileOutputStream(tarFile)) {
- for (String name : files.keySet()) {
- byte[] data = files.get(name).getBytes(UTF_8);
- output.write(new PosixTarHeader.Builder()
- .setName(name)
- .setSize(data.length)
- .build()
- .getBytes());
- output.write(data);
- output.write(new byte[512 - data.length % 512]);
- }
- output.write(new byte[1024]);
- }
- assertThat(tarFile.length() % 512).isEqualTo(0);
- assertThat(tarFile.length() / 512).isEqualTo(files.size() * 2 + 2);
-
- String[] cmd = {"tar", "-xf", tarName};
- String[] env = {"PATH=" + System.getenv("PATH")};
- File cwd = folder.getRoot();
- Process pid = Runtime.getRuntime().exec(cmd, env, cwd);
- String err = CharStreams.toString(new InputStreamReader(pid.getErrorStream(), UTF_8));
- assertThat(pid.waitFor()).isEqualTo(0);
- assertThat(err.trim()).isEmpty();
-
- for (String name : files.keySet()) {
- File file = new File(folder.getRoot(), name);
- assertWithMessage(name + " exists").that(file.exists()).isTrue();
- assertWithMessage(name + " is a file").that(file.isFile()).isTrue();
- byte[] data = files.get(name).getBytes(UTF_8);
- assertThat(Files.asByteSource(file).read()).isEqualTo(data);
- }
- }
-
- @Test
- @Ignore
- public void testReadArchiveUstar() throws Exception {
- assumeTrue(hasCommand("tar"));
-
- String one = "the first line";
- String two = "the second line";
- File cwd = folder.getRoot();
- Files.write(one.getBytes(UTF_8), new File(cwd, "one"));
- Files.write(two.getBytes(UTF_8), new File(cwd, "two"));
-
- String[] cmd = {"tar", "--format=ustar", "-cf", "lines.tar", "one", "two"};
- String[] env = {"PATH=" + System.getenv("PATH")};
- Process pid = Runtime.getRuntime().exec(cmd, env, cwd);
- String err = CharStreams.toString(new InputStreamReader(pid.getErrorStream(), UTF_8));
- assertThat(pid.waitFor()).isEqualTo(0);
- assertThat(err.trim()).isEmpty();
-
- PosixTarHeader header;
- byte[] block = new byte[512];
- try (FileInputStream input = new FileInputStream(new File(cwd, "lines.tar"))) {
- assertThat(input.read(block)).isEqualTo(512);
- header = PosixTarHeader.from(block);
- assertThat(header.getType()).isEqualTo(PosixTarHeader.Type.REGULAR);
- assertThat(header.getName()).isEqualTo("one");
- assertThat(header.getSize()).isEqualTo(one.length());
- assertThat(input.read(block)).isEqualTo(512);
- assertThat(one).isEqualTo(new String(block, 0, one.length(), UTF_8));
-
- assertThat(input.read(block)).isEqualTo(512);
- header = PosixTarHeader.from(block);
- assertThat(header.getType()).isEqualTo(PosixTarHeader.Type.REGULAR);
- assertThat(header.getName()).isEqualTo("two");
- assertThat(header.getSize()).isEqualTo(two.length());
- assertThat(input.read(block)).isEqualTo(512);
- assertThat(two).isEqualTo(new String(block, 0, two.length(), UTF_8));
-
- assertThat(input.read(block)).isEqualTo(512);
- assertWithMessage("End of archive marker corrupt").that(block).isEqualTo(new byte[512]);
- assertThat(input.read(block)).isEqualTo(512);
- assertWithMessage("End of archive marker corrupt").that(block).isEqualTo(new byte[512]);
- }
- }
-
- @Test
- @Ignore
- public void testReadArchiveDefaultFormat() throws Exception {
- assumeTrue(hasCommand("tar"));
-
- String truth = "No one really knows\n";
- Files.write(truth.getBytes(UTF_8), folder.newFile("truth.txt"));
-
- String[] cmd = {"tar", "-cf", "steam.tar", "truth.txt"};
- String[] env = {"PATH=" + System.getenv("PATH")};
- File cwd = folder.getRoot();
- Process pid = Runtime.getRuntime().exec(cmd, env, cwd);
- String err = CharStreams.toString(new InputStreamReader(pid.getErrorStream(), UTF_8));
- assertThat(pid.waitFor()).isEqualTo(0);
- assertThat(err.trim()).isEmpty();
-
- PosixTarHeader header;
- byte[] block = new byte[512];
- try (FileInputStream input = new FileInputStream(new File(cwd, "steam.tar"))) {
- assertThat(input.read(block)).isEqualTo(512);
- header = PosixTarHeader.from(block);
- assertThat(header.getType()).isEqualTo(PosixTarHeader.Type.REGULAR);
- assertThat(header.getName()).isEqualTo("truth.txt");
- assertThat(header.getSize()).isEqualTo(truth.length());
- assertThat(input.read(block)).isEqualTo(512);
- assertThat(truth).isEqualTo(new String(block, 0, truth.length(), UTF_8));
-
- assertThat(input.read(block)).isEqualTo(512);
- assertWithMessage("End of archive marker corrupt").that(block).isEqualTo(new byte[512]);
- assertThat(input.read(block)).isEqualTo(512);
- assertWithMessage("End of archive marker corrupt").that(block).isEqualTo(new byte[512]);
- }
- }
-
- @Test
- @Ignore
- public void testCreateBigWebScaleData() throws Exception {
- assumeTrue(hasCommand("tar"));
-
- String name = "rando_numberissian.mov";
- byte[] data = new byte[4 * 1024 * 1024];
- Random rand = new Random();
- rand.nextBytes(data);
-
- String tarName = "occupy.tar";
- File tarFile = folder.newFile(tarName);
- try (FileOutputStream output = new FileOutputStream(tarFile)) {
- output.write(new PosixTarHeader.Builder()
- .setName(name)
- .setSize(data.length)
- .build()
- .getBytes());
- output.write(data);
- output.write(new byte[1024]);
- }
- assertThat(tarFile.length() % 512).isEqualTo(0);
-
- String[] cmd = {"tar", "-xf", tarName};
- String[] env = {"PATH=" + System.getenv("PATH")};
- File cwd = folder.getRoot();
- Process pid = Runtime.getRuntime().exec(cmd, env, cwd);
- String err = CharStreams.toString(new InputStreamReader(pid.getErrorStream(), UTF_8));
- assertThat(pid.waitFor()).isEqualTo(0);
- assertThat(err.trim()).isEmpty();
-
- File dataFile = new File(cwd, name);
- assertThat(dataFile.exists()).isTrue();
- assertThat(dataFile.isFile()).isTrue();
- assertThat(Files.asByteSource(dataFile).read()).isEqualTo(data);
-
- Set expectedFiles = ImmutableSet.of(tarName, name);
- assertThat(ImmutableSet.copyOf(folder.getRoot().list())).isEqualTo(expectedFiles);
- }
-}
diff --git a/util/src/test/java/google/registry/util/PosixTarHeaderTest.java b/util/src/test/java/google/registry/util/PosixTarHeaderTest.java
index c0d956471..da8a1a70c 100644
--- a/util/src/test/java/google/registry/util/PosixTarHeaderTest.java
+++ b/util/src/test/java/google/registry/util/PosixTarHeaderTest.java
@@ -18,7 +18,7 @@ import static com.google.common.io.BaseEncoding.base64;
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.truth.Truth.assertWithMessage;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.testing.EqualsTester;
import java.io.ByteArrayInputStream;
@@ -28,15 +28,13 @@ import java.util.Arrays;
import java.util.zip.GZIPInputStream;
import org.joda.time.DateTime;
import org.joda.time.format.ISODateTimeFormat;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link PosixTarHeader}. */
-@RunWith(JUnit4.class)
-public class PosixTarHeaderTest {
+class PosixTarHeaderTest {
+
@Test
- public void testGnuTarBlob() throws Exception {
+ void testGnuTarBlob() throws Exception {
// This data was generated as follows:
//
// echo hello kitty >hello.xml
@@ -119,7 +117,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testFields() {
+ void testFields() {
PosixTarHeader header =
new PosixTarHeader.Builder()
.setType(PosixTarHeader.Type.REGULAR)
@@ -146,7 +144,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testFieldsSomeMoar() {
+ void testFieldsSomeMoar() {
PosixTarHeader header =
new PosixTarHeader.Builder()
.setType(PosixTarHeader.Type.DIRECTORY)
@@ -171,7 +169,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testLoad() {
+ void testLoad() {
PosixTarHeader header =
new PosixTarHeader.Builder()
.setType(PosixTarHeader.Type.REGULAR)
@@ -199,7 +197,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testBadChecksum() {
+ void testBadChecksum() {
PosixTarHeader header =
new PosixTarHeader.Builder().setName("(◕‿◕).txt").setSize(31337).build();
byte[] bytes = header.getBytes();
@@ -211,7 +209,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testHashEquals() {
+ void testHashEquals() {
new EqualsTester()
.addEqualityGroup(
new PosixTarHeader.Builder()
@@ -241,7 +239,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testReadBsdTarFormatUstar() throws Exception {
+ void testReadBsdTarFormatUstar() throws Exception {
// $ tar --version
// bsdtar 2.8.3 - libarchive 2.8.3
@@ -299,7 +297,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testReadBsdTarFormatDefault() throws Exception {
+ void testReadBsdTarFormatDefault() throws Exception {
// $ tar --version
// bsdtar 2.8.3 - libarchive 2.8.3
@@ -357,7 +355,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testReadGnuTarFormatDefault() throws Exception {
+ void testReadGnuTarFormatDefault() throws Exception {
// $ tar --version
// tar (GNU tar) 1.26
@@ -415,7 +413,7 @@ public class PosixTarHeaderTest {
}
@Test
- public void testReadGnuTarFormatUstar() throws Exception {
+ void testReadGnuTarFormatUstar() throws Exception {
// $ tar --version
// tar (GNU tar) 1.26
diff --git a/util/src/test/java/google/registry/util/RegistrarUtilsTest.java b/util/src/test/java/google/registry/util/RegistrarUtilsTest.java
index 4881727d8..d369d6b5a 100644
--- a/util/src/test/java/google/registry/util/RegistrarUtilsTest.java
+++ b/util/src/test/java/google/registry/util/RegistrarUtilsTest.java
@@ -16,21 +16,18 @@ package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link RegistrarUtils}. */
-@RunWith(JUnit4.class)
-public class RegistrarUtilsTest {
+class RegistrarUtilsTest {
@Test
- public void testNormalizeRegistrarName_letterOrDigitOnly() {
+ void testNormalizeRegistrarName_letterOrDigitOnly() {
assertThat(RegistrarUtils.normalizeRegistrarName("129abzAZ")).isEqualTo("129abzaz");
}
@Test
- public void testNormalizeRegistrarName_hasSymbols() {
+ void testNormalizeRegistrarName_hasSymbols() {
assertThat(RegistrarUtils.normalizeRegistrarName("^}129a(bzAZ/:")).isEqualTo("129abzaz");
}
}
diff --git a/util/src/test/java/google/registry/util/RetrierTest.java b/util/src/test/java/google/registry/util/RetrierTest.java
index d507093bf..5f219a4d0 100644
--- a/util/src/test/java/google/registry/util/RetrierTest.java
+++ b/util/src/test/java/google/registry/util/RetrierTest.java
@@ -15,21 +15,18 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import google.registry.testing.FakeClock;
import google.registry.testing.FakeSleeper;
import google.registry.util.Retrier.FailureReporter;
import java.util.concurrent.Callable;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link Retrier}. */
-@RunWith(JUnit4.class)
-public class RetrierTest {
+class RetrierTest {
- Retrier retrier = new Retrier(new FakeSleeper(new FakeClock()), 3);
+ private Retrier retrier = new Retrier(new FakeSleeper(new FakeClock()), 3);
/** An exception to throw from {@link CountingThrower}. */
static class CountingException extends RuntimeException {
@@ -70,7 +67,7 @@ public class RetrierTest {
}
@Test
- public void testRetryableException() {
+ void testRetryableException() {
CountingException thrown =
assertThrows(
CountingException.class,
@@ -79,7 +76,7 @@ public class RetrierTest {
}
@Test
- public void testUnretryableException() {
+ void testUnretryableException() {
CountingException thrown =
assertThrows(
CountingException.class,
@@ -88,14 +85,13 @@ public class RetrierTest {
}
@Test
- public void testRetrySucceeded() {
- assertThat(retrier.callWithRetry(new CountingThrower(2), CountingException.class))
- .isEqualTo(2);
+ void testRetrySucceeded() {
+ assertThat(retrier.callWithRetry(new CountingThrower(2), CountingException.class)).isEqualTo(2);
}
@Test
@SuppressWarnings("AssertThrowsMultipleStatements")
- public void testRetryFailed_withReporter() {
+ void testRetryFailed_withReporter() {
CountingException thrown =
assertThrows(
CountingException.class,
@@ -112,7 +108,7 @@ public class RetrierTest {
}
@Test
- public void testRetrySucceeded_withReporter() {
+ void testRetrySucceeded_withReporter() {
TestReporter reporter = new TestReporter();
assertThat(retrier.callWithRetry(new CountingThrower(2), reporter, CountingException.class))
.isEqualTo(2);
@@ -120,7 +116,7 @@ public class RetrierTest {
}
@Test
- public void testFirstTrySucceeded_withReporter() {
+ void testFirstTrySucceeded_withReporter() {
TestReporter reporter = new TestReporter();
assertThat(retrier.callWithRetry(new CountingThrower(0), reporter, CountingException.class))
.isEqualTo(0);
@@ -128,14 +124,14 @@ public class RetrierTest {
}
@Test
- public void testRetryPredicate_succeedsWhenRetries() {
+ void testRetryPredicate_succeedsWhenRetries() {
// Throws a retryable "1" exception is retryable, and then it succeeds on "1".
assertThat(retrier.callWithRetry(new CountingThrower(1), e -> e.getMessage().equals("1")))
.isEqualTo(1);
}
@Test
- public void testRetryPredicate_failsWhenDoesntRetry() {
+ void testRetryPredicate_failsWhenDoesntRetry() {
// Throws a retryable "1" exception, then a non-retryable "2" exception, resulting in failure.
CountingException ex =
assertThrows(
diff --git a/util/src/test/java/google/registry/util/SendEmailServiceTest.java b/util/src/test/java/google/registry/util/SendEmailServiceTest.java
index e42a2ad6d..95fb3c5a4 100644
--- a/util/src/test/java/google/registry/util/SendEmailServiceTest.java
+++ b/util/src/test/java/google/registry/util/SendEmailServiceTest.java
@@ -15,7 +15,7 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.mock;
@@ -32,20 +32,15 @@ import javax.mail.Message.RecipientType;
import javax.mail.MessagingException;
import javax.mail.internet.InternetAddress;
import javax.mail.internet.MimeMultipart;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.extension.ExtendWith;
import org.mockito.ArgumentCaptor;
import org.mockito.Captor;
-import org.mockito.junit.MockitoJUnit;
-import org.mockito.junit.MockitoRule;
+import org.mockito.junit.jupiter.MockitoExtension;
/** Unit tests for {@link SendEmailService}. */
-@RunWith(JUnit4.class)
-public class SendEmailServiceTest {
-
- @Rule public final MockitoRule mocks = MockitoJUnit.rule();
+@ExtendWith(MockitoExtension.class)
+class SendEmailServiceTest {
private final Retrier retrier = new Retrier(new FakeSleeper(new FakeClock()), 2);
private final TransportEmailSender wrapper = mock(TransportEmailSender.class);
@@ -54,7 +49,7 @@ public class SendEmailServiceTest {
@Captor private ArgumentCaptor messageCaptor;
@Test
- public void testSuccess_simple() throws Exception {
+ void testSuccess_simple() throws Exception {
EmailMessage content = createBuilder().build();
sendEmailService.sendEmail(content);
Message message = getMessage();
@@ -73,7 +68,7 @@ public class SendEmailServiceTest {
}
@Test
- public void testSuccess_bcc() throws Exception {
+ void testSuccess_bcc() throws Exception {
EmailMessage content =
createBuilder()
.setBccs(
@@ -90,7 +85,7 @@ public class SendEmailServiceTest {
}
@Test
- public void testSuccess_contentType() throws Exception {
+ void testSuccess_contentType() throws Exception {
EmailMessage content = createBuilder().setContentType(MediaType.HTML_UTF_8).build();
sendEmailService.sendEmail(content);
Message message = getMessage();
@@ -98,7 +93,7 @@ public class SendEmailServiceTest {
}
@Test
- public void testSuccess_attachment() throws Exception {
+ void testSuccess_attachment() throws Exception {
EmailMessage content =
createBuilder()
.setAttachment(
@@ -117,7 +112,7 @@ public class SendEmailServiceTest {
}
@Test
- public void testSuccess_retry() throws Exception {
+ void testSuccess_retry() throws Exception {
doThrow(new MessagingException("hi"))
.doNothing()
.when(wrapper)
@@ -128,7 +123,7 @@ public class SendEmailServiceTest {
}
@Test
- public void testFailure_wrongExceptionType() throws Exception {
+ void testFailure_wrongExceptionType() throws Exception {
doThrow(new RuntimeException("this is a runtime exception")).when(wrapper).sendMessage(any());
EmailMessage content = createBuilder().build();
RuntimeException thrown =
@@ -137,7 +132,7 @@ public class SendEmailServiceTest {
}
@Test
- public void testFailure_tooManyTries() throws Exception {
+ void testFailure_tooManyTries() throws Exception {
doThrow(new MessagingException("hi"))
.doThrow(new MessagingException("second"))
.when(wrapper)
diff --git a/util/src/test/java/google/registry/util/SerializeUtilsTest.java b/util/src/test/java/google/registry/util/SerializeUtilsTest.java
index 5eacc72c2..67baf6b9e 100644
--- a/util/src/test/java/google/registry/util/SerializeUtilsTest.java
+++ b/util/src/test/java/google/registry/util/SerializeUtilsTest.java
@@ -17,15 +17,12 @@ package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
import static google.registry.util.SerializeUtils.deserialize;
import static google.registry.util.SerializeUtils.serialize;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link SerializeUtils}. */
-@RunWith(JUnit4.class)
-public class SerializeUtilsTest {
+class SerializeUtilsTest {
static class Lol {
@Override
@@ -33,30 +30,31 @@ public class SerializeUtilsTest {
return "LOL_VALUE";
}
}
+
@Test
- public void testSerialize_nullValue_returnsNull() {
+ void testSerialize_nullValue_returnsNull() {
assertThat(serialize(null)).isNull();
}
@Test
- public void testDeserialize_nullValue_returnsNull() {
+ void testDeserialize_nullValue_returnsNull() {
assertThat(deserialize(Object.class, null)).isNull();
}
@Test
- public void testSerializeDeserialize_stringValue_maintainsValue() {
+ void testSerializeDeserialize_stringValue_maintainsValue() {
assertThat(deserialize(String.class, serialize("hello"))).isEqualTo("hello");
}
@Test
- public void testSerialize_objectDoesntImplementSerialize_hasInformativeError() {
+ void testSerialize_objectDoesntImplementSerialize_hasInformativeError() {
IllegalArgumentException thrown =
assertThrows(IllegalArgumentException.class, () -> serialize(new Lol()));
assertThat(thrown).hasMessageThat().contains("Unable to serialize: LOL_VALUE");
}
@Test
- public void testDeserialize_badValue_hasInformativeError() {
+ void testDeserialize_badValue_hasInformativeError() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
diff --git a/util/src/test/java/google/registry/util/SqlTemplateTest.java b/util/src/test/java/google/registry/util/SqlTemplateTest.java
index dbbb736e0..4bf29a7a2 100644
--- a/util/src/test/java/google/registry/util/SqlTemplateTest.java
+++ b/util/src/test/java/google/registry/util/SqlTemplateTest.java
@@ -15,39 +15,30 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link SqlTemplate}. */
-@RunWith(JUnit4.class)
-public class SqlTemplateTest {
+class SqlTemplateTest {
@Test
- public void testFillSqlTemplate() {
+ void testFillSqlTemplate() {
+ assertThat(SqlTemplate.create("%TEST%").put("TEST", "hello world").build())
+ .isEqualTo("hello world");
+ assertThat(SqlTemplate.create("one %TWO% three").put("TWO", "2").build())
+ .isEqualTo("one 2 three");
assertThat(
- SqlTemplate.create("%TEST%")
- .put("TEST", "hello world")
- .build())
- .isEqualTo("hello world");
- assertThat(
- SqlTemplate.create("one %TWO% three")
- .put("TWO", "2")
- .build())
- .isEqualTo("one 2 three");
- assertThat(
- SqlTemplate.create("%ONE% %TWO% %THREE%")
- .put("ONE", "1")
- .put("TWO", "2")
- .put("THREE", "3")
- .build())
- .isEqualTo("1 2 3");
+ SqlTemplate.create("%ONE% %TWO% %THREE%")
+ .put("ONE", "1")
+ .put("TWO", "2")
+ .put("THREE", "3")
+ .build())
+ .isEqualTo("1 2 3");
}
@Test
- public void testFillSqlTemplate_substitutionButNoVariables() {
+ void testFillSqlTemplate_substitutionButNoVariables() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class, () -> SqlTemplate.create("").put("ONE", "1").build());
@@ -55,7 +46,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_substitutionButMissingVariables() {
+ void testFillSqlTemplate_substitutionButMissingVariables() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -64,7 +55,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_sameKeyTwice_failsEarly() {
+ void testFillSqlTemplate_sameKeyTwice_failsEarly() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -73,7 +64,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_variablesButNotEnoughSubstitutions() {
+ void testFillSqlTemplate_variablesButNotEnoughSubstitutions() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -82,7 +73,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_mismatchedVariableAndSubstitution() {
+ void testFillSqlTemplate_mismatchedVariableAndSubstitution() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -91,14 +82,14 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_missingKeyVals_whatsThePoint() {
+ void testFillSqlTemplate_missingKeyVals_whatsThePoint() {
IllegalArgumentException thrown =
assertThrows(IllegalArgumentException.class, () -> SqlTemplate.create("%TWO%").build());
assertThat(thrown).hasMessageThat().contains("%TWO% found in template but no substitution");
}
@Test
- public void testFillSqlTemplate_lowercaseKey_notAllowed() {
+ void testFillSqlTemplate_lowercaseKey_notAllowed() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -107,7 +98,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_substitution_disallowsSingleQuotes() {
+ void testFillSqlTemplate_substitution_disallowsSingleQuotes() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -116,7 +107,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_substitution_disallowsDoubleQuotes() {
+ void testFillSqlTemplate_substitution_disallowsDoubleQuotes() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -125,7 +116,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_quoteMismatch_throwsError() {
+ void testFillSqlTemplate_quoteMismatch_throwsError() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -135,7 +126,7 @@ public class SqlTemplateTest {
}
@Test
- public void testFillSqlTemplate_extendedQuote_throwsError() {
+ void testFillSqlTemplate_extendedQuote_throwsError() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
diff --git a/util/src/test/java/google/registry/util/TeeOutputStreamTest.java b/util/src/test/java/google/registry/util/TeeOutputStreamTest.java
index ef6257381..b813b0778 100644
--- a/util/src/test/java/google/registry/util/TeeOutputStreamTest.java
+++ b/util/src/test/java/google/registry/util/TeeOutputStreamTest.java
@@ -17,28 +17,25 @@ package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
import static java.nio.charset.StandardCharsets.UTF_8;
import static java.util.Arrays.asList;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
import java.io.ByteArrayOutputStream;
import java.io.OutputStream;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link TeeOutputStream}. */
-@RunWith(JUnit4.class)
-public class TeeOutputStreamTest {
+class TeeOutputStreamTest {
+
private final ByteArrayOutputStream outputA = new ByteArrayOutputStream();
private final ByteArrayOutputStream outputB = new ByteArrayOutputStream();
private final ByteArrayOutputStream outputC = new ByteArrayOutputStream();
@Test
- public void testWrite_writesToMultipleStreams() throws Exception {
+ void testWrite_writesToMultipleStreams() throws Exception {
// Write shared data using the tee output stream.
- try (OutputStream tee =
- new TeeOutputStream(asList(outputA, outputB, outputC))) {
+ try (OutputStream tee = new TeeOutputStream(asList(outputA, outputB, outputC))) {
tee.write("hello ".getBytes(UTF_8));
tee.write("hello world!".getBytes(UTF_8), 6, 5);
tee.write('!');
@@ -55,12 +52,12 @@ public class TeeOutputStreamTest {
@Test
@SuppressWarnings("resource")
- public void testConstructor_failsWithEmptyIterable() {
+ void testConstructor_failsWithEmptyIterable() {
assertThrows(IllegalArgumentException.class, () -> new TeeOutputStream(ImmutableSet.of()));
}
@Test
- public void testWriteInteger_failsAfterClose() throws Exception {
+ void testWriteInteger_failsAfterClose() throws Exception {
OutputStream tee = new TeeOutputStream(ImmutableList.of(outputA));
tee.close();
IllegalStateException thrown = assertThrows(IllegalStateException.class, () -> tee.write(1));
@@ -68,7 +65,7 @@ public class TeeOutputStreamTest {
}
@Test
- public void testWriteByteArray_failsAfterClose() throws Exception {
+ void testWriteByteArray_failsAfterClose() throws Exception {
OutputStream tee = new TeeOutputStream(ImmutableList.of(outputA));
tee.close();
IllegalStateException thrown =
@@ -77,7 +74,7 @@ public class TeeOutputStreamTest {
}
@Test
- public void testWriteByteSubarray_failsAfterClose() throws Exception {
+ void testWriteByteSubarray_failsAfterClose() throws Exception {
OutputStream tee = new TeeOutputStream(ImmutableList.of(outputA));
tee.close();
IllegalStateException thrown =
diff --git a/util/src/test/java/google/registry/util/TypeUtilsTest.java b/util/src/test/java/google/registry/util/TypeUtilsTest.java
index 915ed39aa..aca947842 100644
--- a/util/src/test/java/google/registry/util/TypeUtilsTest.java
+++ b/util/src/test/java/google/registry/util/TypeUtilsTest.java
@@ -15,26 +15,24 @@
package google.registry.util;
import static com.google.common.truth.Truth.assertThat;
-import static org.junit.Assert.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertThrows;
import java.io.Serializable;
import java.util.ArrayList;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.JUnit4;
+import org.junit.jupiter.api.Test;
/** Unit tests for {@link TypeUtils}. */
-@RunWith(JUnit4.class)
-public class TypeUtilsTest {
+class TypeUtilsTest {
+
@Test
- public void test_getClassFromString_validClass() {
+ void test_getClassFromString_validClass() {
Class extends Serializable> clazz =
TypeUtils.getClassFromString("java.util.ArrayList", Serializable.class);
assertThat(clazz).isEqualTo(ArrayList.class);
}
@Test
- public void test_getClassFromString_notAssignableFrom() {
+ void test_getClassFromString_notAssignableFrom() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -43,7 +41,7 @@ public class TypeUtilsTest {
}
@Test
- public void test_getClassFromString_unknownClass() {
+ void test_getClassFromString_unknownClass() {
IllegalArgumentException thrown =
assertThrows(
IllegalArgumentException.class,
@@ -62,7 +60,7 @@ public class TypeUtilsTest {
}
@Test
- public void test_instantiateWithArg() {
+ void test_instantiateWithArg() {
Class clazz =
TypeUtils.getClassFromString(
"google.registry.util.TypeUtilsTest$ExampleClass", ExampleClass.class);