templatesUnderTest() {
- // XXX: Drop the filter once we have added tests for AssertJ!
- return TEMPLATES_BY_GROUP.entries().stream()
- .filter(e -> !"AssertJ".equals(e.getKey()))
- .map(e -> arguments(e.getKey(), e.getValue()));
- }
-
- /**
- * Verifies that {@link Refaster#loadAllCodeTransformers} finds at least one code transformer for
- * all of the {@link #TEMPLATE_GROUPS}.
- *
- * This test is just as much about ensuring that {@link #TEMPLATE_GROUPS} is exhaustive, so
- * that in turn {@link #replacement}'s coverage is exhaustive.
- */
- @Test
- void loadAllCodeTransformers() {
- assertThat(TEMPLATES_BY_GROUP.keySet()).hasSameElementsAs(TEMPLATE_GROUPS);
- }
-
- /**
- * Verifies for each of the {@link #TEMPLATE_GROUPS} that the associated code transformers have
- * the desired effect.
- */
- @MethodSource("templateGroupsUnderTest")
- @ParameterizedTest
- void replacement(String group) {
- verifyRefactoring(group, namePattern(group));
- }
-
- /**
- * Verifies that all loaded Refaster templates are covered by at least one test.
- *
- *
Note that this doesn't guarantee full coverage: this test cannot ascertain that all {@link
- * com.google.errorprone.refaster.Refaster#anyOf} branches are tested. Idem for {@link
- * com.google.errorprone.refaster.annotation.BeforeTemplate} methods in case there are multiple .
- */
- @MethodSource("templatesUnderTest")
- @ParameterizedTest
- void coverage(String group, String template) {
- assertThatCode(() -> verifyRefactoring(group, namePattern(group, template)))
- .withFailMessage(
- "Template %s does not affect the tests for group %s; is it tested?", template, group)
- .isInstanceOf(ComparisonFailure.class);
- }
-
- private static ImmutableSetMultimap indexTemplateNamesByGroup(
- ImmutableSet templateNames) {
- return templateNames.stream()
- .collect(
- toImmutableSetMultimap(
- n -> TEMPLATE_FQCN_TRIM_FOR_GROUP_NAME.matcher(n).replaceAll(""), identity()));
- }
-
- private static String namePattern(String groupName, String excludedTemplate) {
- return "(?!" + Pattern.quote(excludedTemplate) + ')' + namePattern(groupName);
- }
-
- private static String namePattern(String groupName) {
- return Pattern.compile(Pattern.quote(groupName)) + "Templates.*";
- }
-
- private void verifyRefactoring(String groupName, String templateNamePattern) {
- createRestrictedRefactoringTestHelper(templateNamePattern)
- .addInput(groupName + "TemplatesTestInput.java")
- .addOutput(groupName + "TemplatesTestOutput.java")
- .doTest(TestMode.TEXT_MATCH);
- }
-
- private BugCheckerRefactoringTestHelper createRestrictedRefactoringTestHelper(
- String namePattern) {
- return BugCheckerRefactoringTestHelper.newInstance(
- Refaster.class, getRefasterTemplateCollectionClass())
- .setArgs("-XepOpt:Refaster:NamePattern=" + namePattern);
- }
-
- /**
- * Returns an arbitrary Refaster template collection class inside the {@code
- * tech.picnic.errorprone.refastertemplates} package, enabling {@link
- * BugCheckerRefactoringTestHelper} to load test resources from said package.
- */
- private Class> getRefasterTemplateCollectionClass() {
- try {
- return Class.forName(
- "tech.picnic.errorprone.refastertemplates.AssortedTemplates",
- /* initialize= */ false,
- getClass().getClassLoader());
- } catch (ClassNotFoundException e) {
- throw new IllegalStateException("Failed to load Refaster template collection class", e);
- }
- }
-}
diff --git a/error-prone-contrib/src/test/java/tech/picnic/errorprone/refastertemplates/RefasterTemplatesTest.java b/error-prone-contrib/src/test/java/tech/picnic/errorprone/refastertemplates/RefasterTemplatesTest.java
new file mode 100644
index 0000000000..7b78e49475
--- /dev/null
+++ b/error-prone-contrib/src/test/java/tech/picnic/errorprone/refastertemplates/RefasterTemplatesTest.java
@@ -0,0 +1,81 @@
+package tech.picnic.errorprone.refastertemplates;
+
+import static java.util.function.Predicate.not;
+
+import com.google.common.collect.ImmutableSet;
+import java.util.stream.Stream;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.Arguments;
+import org.junit.jupiter.params.provider.MethodSource;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateCollection;
+
+final class RefasterTemplatesTest {
+ /** The names of all Refaster template groups defined in this module. */
+ private static final ImmutableSet> TEMPLATE_COLLECTIONS =
+ ImmutableSet.of(
+ AssertJTemplates.class,
+ AssertJBigDecimalTemplates.class,
+ AssertJBigIntegerTemplates.class,
+ AssertJBooleanTemplates.class,
+ AssertJByteTemplates.class,
+ AssertJCharSequenceTemplates.class,
+ AssertJDoubleTemplates.class,
+ AssertJEnumerableTemplates.class,
+ AssertJFloatTemplates.class,
+ AssertJIntegerTemplates.class,
+ AssertJLongTemplates.class,
+ AssertJNumberTemplates.class,
+ AssertJMapTemplates.class,
+ AssertJObjectTemplates.class,
+ AssertJOptionalTemplates.class,
+ AssertJShortTemplates.class,
+ AssertJStringTemplates.class,
+ AssertJThrowingCallableTemplates.class,
+ AssortedTemplates.class,
+ BigDecimalTemplates.class,
+ CollectionTemplates.class,
+ ComparatorTemplates.class,
+ DoubleStreamTemplates.class,
+ EqualityTemplates.class,
+ ImmutableListTemplates.class,
+ ImmutableListMultimapTemplates.class,
+ ImmutableMapTemplates.class,
+ ImmutableMultisetTemplates.class,
+ ImmutableSetTemplates.class,
+ ImmutableSetMultimapTemplates.class,
+ ImmutableSortedMapTemplates.class,
+ ImmutableSortedMultisetTemplates.class,
+ ImmutableSortedSetTemplates.class,
+ IntStreamTemplates.class,
+ JUnitTemplates.class,
+ LongStreamTemplates.class,
+ MapEntryTemplates.class,
+ MockitoTemplates.class,
+ MultimapTemplates.class,
+ NullTemplates.class,
+ OptionalTemplates.class,
+ PrimitiveTemplates.class,
+ ReactorTemplates.class,
+ RxJava2AdapterTemplates.class,
+ StreamTemplates.class,
+ StringTemplates.class,
+ TestNGToAssertJTemplates.class,
+ TimeTemplates.class,
+ WebClientTemplates.class);
+
+ // XXX: Create a JUnit extension to automatically discover the template collections in a given
+ // context to make sure the list is exhaustive.
+ private static Stream validateTemplateCollectionTestCases() {
+ // XXX: Drop the filter once we have added tests for AssertJ! We can then also replace this
+ // method with `@ValueSource(classes = {...})`.
+ return TEMPLATE_COLLECTIONS.stream()
+ .filter(not(AssertJTemplates.class::equals))
+ .map(Arguments::arguments);
+ }
+
+ @MethodSource("validateTemplateCollectionTestCases")
+ @ParameterizedTest
+ void validateTemplateCollection(Class> clazz) {
+ RefasterTemplateCollection.validate(clazz);
+ }
+}
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestInput.java
index 370a6cf13b..c8ecc2ecb8 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestInput.java
@@ -7,6 +7,7 @@
import com.google.common.collect.ImmutableSet;
import java.math.BigDecimal;
import org.assertj.core.api.AbstractBigDecimalAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJBigDecimalTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestOutput.java
index c3cb6e3f25..9807aa5488 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigDecimalTemplatesTestOutput.java
@@ -7,6 +7,7 @@
import com.google.common.collect.ImmutableSet;
import java.math.BigDecimal;
import org.assertj.core.api.AbstractBigDecimalAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJBigDecimalTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestInput.java
index 7aab3da716..3bbbcf0380 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestInput.java
@@ -7,6 +7,7 @@
import com.google.common.collect.ImmutableSet;
import java.math.BigInteger;
import org.assertj.core.api.AbstractBigIntegerAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJBigIntegerTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestOutput.java
index 9106ecdcb2..9674b649dd 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBigIntegerTemplatesTestOutput.java
@@ -7,6 +7,7 @@
import com.google.common.collect.ImmutableSet;
import java.math.BigInteger;
import org.assertj.core.api.AbstractBigIntegerAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJBigIntegerTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestInput.java
index 1193dc6f0d..9181a58247 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestInput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractBooleanAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJBooleanTemplatesTest implements RefasterTemplateTestCase {
AbstractBooleanAssert> testAbstractBooleanAssertIsEqualTo() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestOutput.java
index 110a421c28..da458b13b9 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJBooleanTemplatesTestOutput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractBooleanAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJBooleanTemplatesTest implements RefasterTemplateTestCase {
AbstractBooleanAssert> testAbstractBooleanAssertIsEqualTo() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestInput.java
index 5c0e7a7834..f9a7b2607e 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractByteAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJByteTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestOutput.java
index 6bf3250142..ea274127a4 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJByteTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractByteAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJByteTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestInput.java
index 5a71e7a6a8..3cad90b1a0 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestInput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJCharSequenceTemplatesTest implements RefasterTemplateTestCase {
void testAssertThatCharSequenceIsEmpty() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestOutput.java
index 6395d7258a..9d0fc29bb3 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJCharSequenceTemplatesTestOutput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJCharSequenceTemplatesTest implements RefasterTemplateTestCase {
void testAssertThatCharSequenceIsEmpty() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestInput.java
index 95fb107dbf..04eb0c7206 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractDoubleAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJDoubleTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestOutput.java
index d657c3dde8..12ec9c93be 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJDoubleTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractDoubleAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJDoubleTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestInput.java
index 693fd1c4af..7374a993eb 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestInput.java
@@ -5,6 +5,7 @@
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.Iterables;
import org.assertj.core.api.EnumerableAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJEnumableTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestOutput.java
index 5b7e9013e4..598a38168f 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJEnumerableTemplatesTestOutput.java
@@ -5,6 +5,7 @@
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.Iterables;
import org.assertj.core.api.EnumerableAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJEnumableTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestInput.java
index 88ced7b924..54b4fac623 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractFloatAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJFloatTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestOutput.java
index 01dc692db7..40b9626372 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJFloatTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractFloatAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJFloatTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestInput.java
index 320496d205..6b4b7a38c3 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractIntegerAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJIntegerTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestOutput.java
index da912f04e3..87613912ff 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJIntegerTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractIntegerAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJIntegerTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestInput.java
index cee37b2227..b55a52774f 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractLongAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJLongTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestOutput.java
index 5a54440edf..1c7a851983 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJLongTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractLongAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJLongTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestInput.java
index 020b18a476..84d9fb02d3 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestInput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableMap;
import org.assertj.core.api.AbstractMapAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJMapTemplatesTest implements RefasterTemplateTestCase {
AbstractMapAssert, ?, Integer, Integer>
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestOutput.java
index ff2a771151..65d1a3b4cb 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJMapTemplatesTestOutput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableMap;
import org.assertj.core.api.AbstractMapAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJMapTemplatesTest implements RefasterTemplateTestCase {
AbstractMapAssert, ?, Integer, Integer>
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestInput.java
index 22193c9dcd..d92b1cdf14 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestInput.java
@@ -6,6 +6,7 @@
import java.math.BigDecimal;
import java.math.BigInteger;
import org.assertj.core.api.NumberAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJNumberTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet> testNumberAssertIsPositive() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestOutput.java
index a01f1b490f..72b9f27ce4 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJNumberTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import java.math.BigDecimal;
import java.math.BigInteger;
import org.assertj.core.api.NumberAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJNumberTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet> testNumberAssertIsPositive() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestInput.java
index 521143a501..391c6b1228 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestInput.java
@@ -3,6 +3,7 @@
import static org.assertj.core.api.Assertions.assertThat;
import org.assertj.core.api.AbstractAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJObjectTemplatesTest implements RefasterTemplateTestCase {
AbstractAssert, ?> testAssertThatIsInstanceOf() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestOutput.java
index 35a273a7d0..3e68603b4a 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJObjectTemplatesTestOutput.java
@@ -3,6 +3,7 @@
import static org.assertj.core.api.Assertions.assertThat;
import org.assertj.core.api.AbstractAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJObjectTemplatesTest implements RefasterTemplateTestCase {
AbstractAssert, ?> testAssertThatIsInstanceOf() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestInput.java
index 86f91856b5..ca6be8ec0b 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestInput.java
@@ -6,6 +6,7 @@
import java.util.Optional;
import org.assertj.core.api.AbstractAssert;
import org.assertj.core.api.OptionalAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJOptionalTemplatesTest implements RefasterTemplateTestCase {
AbstractAssert, ?> testAssertThatOptional() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestOutput.java
index 29bb84d576..df5f706c31 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJOptionalTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import java.util.Optional;
import org.assertj.core.api.AbstractAssert;
import org.assertj.core.api.OptionalAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJOptionalTemplatesTest implements RefasterTemplateTestCase {
AbstractAssert, ?> testAssertThatOptional() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestInput.java
index c79f5d2f8f..e4fc739373 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractShortAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJShortTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestOutput.java
index d051c08034..58beb71e24 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJShortTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractShortAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJShortTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestInput.java
index 4023eb1f60..e699740a83 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestInput.java
@@ -4,6 +4,7 @@
import org.assertj.core.api.AbstractAssert;
import org.assertj.core.api.AbstractStringAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJStringTemplatesTest implements RefasterTemplateTestCase {
void testAbstractStringAssertStringIsEmpty() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestOutput.java
index 759b00f0cb..1e048f94a2 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJStringTemplatesTestOutput.java
@@ -4,6 +4,7 @@
import org.assertj.core.api.AbstractAssert;
import org.assertj.core.api.AbstractStringAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJStringTemplatesTest implements RefasterTemplateTestCase {
void testAbstractStringAssertStringIsEmpty() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestInput.java
index 4101c67f75..b4c202ec09 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestInput.java
@@ -10,6 +10,7 @@
import com.google.common.collect.ImmutableSet;
import org.assertj.core.api.AbstractObjectAssert;
import org.assertj.core.api.AbstractThrowableAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJThrowingCallableTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestOutput.java
index 5b65c5f6c4..eed84befbb 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssertJThrowingCallableTemplatesTestOutput.java
@@ -11,6 +11,7 @@
import java.io.IOException;
import org.assertj.core.api.AbstractObjectAssert;
import org.assertj.core.api.AbstractThrowableAssert;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssertJThrowingCallableTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestInput.java
index efa49a9753..d4023e4546 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestInput.java
@@ -17,6 +17,7 @@
import java.util.HashSet;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssortedTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestOutput.java
index ea92986131..10809a7134 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/AssortedTemplatesTestOutput.java
@@ -21,6 +21,7 @@
import java.util.Map;
import java.util.Objects;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class AssortedTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestInput.java
index 8ccae257f3..878b1bac28 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestInput.java
@@ -2,6 +2,7 @@
import com.google.common.collect.ImmutableSet;
import java.math.BigDecimal;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class BigDecimalTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet testBigDecimalZero() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestOutput.java
index e92630e76a..1a379ce9f7 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/BigDecimalTemplatesTestOutput.java
@@ -2,6 +2,7 @@
import com.google.common.collect.ImmutableSet;
import java.math.BigDecimal;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class BigDecimalTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet testBigDecimalZero() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestInput.java
index 33421b1e7f..b2509efd1b 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestInput.java
@@ -12,6 +12,7 @@
import java.util.Optional;
import java.util.TreeSet;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class CollectionTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestOutput.java
index 0ae34afdb2..cbbf3dbdae 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/CollectionTemplatesTestOutput.java
@@ -12,6 +12,7 @@
import java.util.Optional;
import java.util.TreeSet;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class CollectionTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestInput.java
index 406b1da7b3..39c10f8add 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestInput.java
@@ -8,6 +8,7 @@
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ComparatorTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestOutput.java
index 77da76b222..366da20139 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ComparatorTemplatesTestOutput.java
@@ -10,6 +10,7 @@
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ComparatorTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestInput.java
index fe20205972..37bd64f8f7 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestInput.java
@@ -6,6 +6,7 @@
import java.util.function.DoublePredicate;
import java.util.stream.DoubleStream;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class DoubleStreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestOutput.java
index 75b0e8993f..de39e49000 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/DoubleStreamTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import java.util.function.DoublePredicate;
import java.util.stream.DoubleStream;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class DoubleStreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestInput.java
index f331f88586..f8299fc8ad 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestInput.java
@@ -5,6 +5,7 @@
import java.math.RoundingMode;
import java.util.Objects;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class EqualityTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestOutput.java
index c5ac531191..f142f465f1 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/EqualityTemplatesTestOutput.java
@@ -5,6 +5,7 @@
import java.math.RoundingMode;
import java.util.Objects;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class EqualityTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestInput.java
index be01cdaf0e..f840b67d17 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestInput.java
@@ -16,6 +16,7 @@
import com.google.common.collect.TreeMultimap;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableListMultimapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestOutput.java
index cdbb663ea8..7f7e7888b0 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListMultimapTemplatesTestOutput.java
@@ -16,6 +16,7 @@
import com.google.common.collect.TreeMultimap;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableListMultimapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestInput.java
index 1a93261fd8..0afd20b0e1 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestInput.java
@@ -11,6 +11,7 @@
import java.util.Comparator;
import java.util.List;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableListTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestOutput.java
index 1ba66ba42e..915ab1e1df 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableListTemplatesTestOutput.java
@@ -12,6 +12,7 @@
import java.util.Comparator;
import java.util.List;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableListTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestInput.java
index 5995d955d7..b2667b9f58 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestInput.java
@@ -12,6 +12,7 @@
import java.util.Collections;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableMapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestOutput.java
index 36d7b5bdae..77153c7466 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMapTemplatesTestOutput.java
@@ -12,6 +12,7 @@
import java.util.Collections;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableMapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestInput.java
index ef50b18791..92f4ed84f1 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestInput.java
@@ -8,6 +8,7 @@
import com.google.common.collect.Streams;
import java.util.Arrays;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableMultisetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestOutput.java
index 6004eafaf4..84f5122d84 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableMultisetTemplatesTestOutput.java
@@ -8,6 +8,7 @@
import com.google.common.collect.Streams;
import java.util.Arrays;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableMultisetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestInput.java
index 3d3ac31850..2f2cd08f0c 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestInput.java
@@ -13,6 +13,7 @@
import com.google.common.collect.TreeMultimap;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSetMultimapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestOutput.java
index 647d9b96b3..f887977a8b 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetMultimapTemplatesTestOutput.java
@@ -13,6 +13,7 @@
import com.google.common.collect.TreeMultimap;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSetMultimapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestInput.java
index 29891c942b..d2b38ad2ac 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestInput.java
@@ -10,6 +10,7 @@
import java.util.Collections;
import java.util.Set;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestOutput.java
index 3943f5908f..e6ad2e44ad 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSetTemplatesTestOutput.java
@@ -10,6 +10,7 @@
import java.util.Collections;
import java.util.Set;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestInput.java
index 1443707ece..a2df4ae2b0 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestInput.java
@@ -10,6 +10,7 @@
import java.util.Comparator;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSortedMapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestOutput.java
index 98c212f89f..7f394fa1f1 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMapTemplatesTestOutput.java
@@ -10,6 +10,7 @@
import java.util.Comparator;
import java.util.Map;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSortedMapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestInput.java
index f42fd53211..085fb1e8c6 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestInput.java
@@ -11,6 +11,7 @@
import java.util.Arrays;
import java.util.Comparator;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSortedMultisetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestOutput.java
index 818a933154..843c2922e6 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedMultisetTemplatesTestOutput.java
@@ -11,6 +11,7 @@
import java.util.Arrays;
import java.util.Comparator;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSortedMultisetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestInput.java
index 02181575c0..4a90a87457 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestInput.java
@@ -10,6 +10,7 @@
import java.util.Arrays;
import java.util.Comparator;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSortedSetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestOutput.java
index 2d696c95fe..b944a2ef31 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ImmutableSortedSetTemplatesTestOutput.java
@@ -10,6 +10,7 @@
import java.util.Arrays;
import java.util.Comparator;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ImmutableSortedSetTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestInput.java
index fe7d93763d..03cf380352 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestInput.java
@@ -6,6 +6,7 @@
import java.util.function.IntPredicate;
import java.util.stream.IntStream;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class IntStreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestOutput.java
index 30260b53d6..c40930f27a 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/IntStreamTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import java.util.function.IntPredicate;
import java.util.stream.IntStream;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class IntStreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestInput.java
index 88d26b05f4..77c83e8916 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestInput.java
@@ -2,6 +2,7 @@
import com.google.common.collect.ImmutableSet;
import org.junit.jupiter.params.provider.Arguments;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class JUnitTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet testArgumentsEnumeration() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestOutput.java
index 6e8e77582c..13151144b2 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/JUnitTemplatesTestOutput.java
@@ -4,6 +4,7 @@
import com.google.common.collect.ImmutableSet;
import org.junit.jupiter.params.provider.Arguments;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class JUnitTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet testArgumentsEnumeration() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestInput.java
index fd284c65fe..51a32a1d3a 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestInput.java
@@ -6,6 +6,7 @@
import java.util.function.LongPredicate;
import java.util.stream.LongStream;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class LongStreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestOutput.java
index 6b1b54229a..c87219b7fd 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/LongStreamTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import java.util.function.LongPredicate;
import java.util.stream.LongStream;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class LongStreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestInput.java
index c9203ab5ee..e829d26833 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestInput.java
@@ -5,6 +5,7 @@
import java.util.AbstractMap;
import java.util.Comparator;
import java.util.Map;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class MapEntryTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestOutput.java
index bf1327aeb7..056bb169ee 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MapEntryTemplatesTestOutput.java
@@ -8,6 +8,7 @@
import java.util.AbstractMap;
import java.util.Comparator;
import java.util.Map;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class MapEntryTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestInput.java
index 676a15f5c1..f48eec9c48 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import org.mockito.verification.VerificationMode;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class MockitoTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestOutput.java
index 258fab726a..367ffba744 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MockitoTemplatesTestOutput.java
@@ -7,6 +7,7 @@
import com.google.common.collect.ImmutableSet;
import org.mockito.verification.VerificationMode;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class MockitoTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestInput.java
index 5528056bbd..3348249ba7 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestInput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.Multimaps;
import java.util.Collection;
import java.util.Set;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class MultimapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestOutput.java
index 5c027237fb..0aeab3fc01 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/MultimapTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.Multimaps;
import java.util.Collection;
import java.util.Set;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class MultimapTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestInput.java
index 7b28ad4ae0..ac02a7b084 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestInput.java
@@ -3,6 +3,7 @@
import com.google.common.base.MoreObjects;
import com.google.common.collect.ImmutableSet;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class NullTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestOutput.java
index cda3ab9634..617aa31dbc 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/NullTemplatesTestOutput.java
@@ -6,6 +6,7 @@
import com.google.common.collect.ImmutableSet;
import java.util.Objects;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class NullTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestInput.java
index a954478eb0..d32ba426d2 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestInput.java
@@ -5,6 +5,7 @@
import java.util.Optional;
import java.util.function.Function;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class OptionalTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestOutput.java
index 100d8aca28..d7e4f8573f 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/OptionalTemplatesTestOutput.java
@@ -7,6 +7,7 @@
import java.util.Optional;
import java.util.function.Function;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class OptionalTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestInput.java
index 1580b6063a..d41931b501 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestInput.java
@@ -2,6 +2,7 @@
import com.google.common.collect.ImmutableSet;
import com.google.common.primitives.Ints;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class PrimitiveTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestOutput.java
index 91caf7c011..ba2647ad83 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/PrimitiveTemplatesTestOutput.java
@@ -2,6 +2,7 @@
import com.google.common.collect.ImmutableSet;
import com.google.common.primitives.Ints;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class PrimitiveTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestInput.java
index ca0bd1d486..0fc64f7670 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestInput.java
@@ -11,6 +11,7 @@
import reactor.core.publisher.Mono;
import reactor.test.StepVerifier;
import reactor.test.publisher.PublisherProbe;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ReactorTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestOutput.java
index 90f73ae0ba..18fd8b92b9 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/ReactorTemplatesTestOutput.java
@@ -12,6 +12,7 @@
import reactor.core.publisher.Mono;
import reactor.test.StepVerifier;
import reactor.test.publisher.PublisherProbe;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class ReactorTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestInput.java
index 7169ebfb98..42fc8b73c6 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestInput.java
@@ -12,6 +12,7 @@
import reactor.adapter.rxjava.RxJava2Adapter;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class RxJava2AdapterTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet> testCompletableToMono() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestOutput.java
index 4a523d60e6..6ad2980890 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/RxJava2AdapterTemplatesTestOutput.java
@@ -12,6 +12,7 @@
import reactor.adapter.rxjava.RxJava2Adapter;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class RxJava2AdapterTemplatesTest implements RefasterTemplateTestCase {
ImmutableSet> testCompletableToMono() {
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestInput.java
index 2384fa9409..f59538c6b0 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestInput.java
@@ -11,6 +11,7 @@
import java.util.Optional;
import java.util.function.Predicate;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class StreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestOutput.java
index 071f789045..c41746138d 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StreamTemplatesTestOutput.java
@@ -13,6 +13,7 @@
import java.util.Optional;
import java.util.function.Predicate;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class StreamTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestInput.java
index 3d2b50ec31..bbf600371a 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestInput.java
@@ -12,6 +12,7 @@
import java.util.Arrays;
import java.util.Optional;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class StringTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestOutput.java
index 4f9067c88c..b37280462f 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/StringTemplatesTestOutput.java
@@ -13,6 +13,7 @@
import java.util.Arrays;
import java.util.Optional;
import java.util.stream.Stream;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class StringTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestInput.java
index 67bc31e03c..34d0a9fd48 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestInput.java
@@ -17,6 +17,7 @@
import com.google.common.collect.Iterators;
import java.util.ArrayList;
import java.util.Collections;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class TestNGToAssertJTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestOutput.java
index 8e10a5ef06..496620306b 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TestNGToAssertJTemplatesTestOutput.java
@@ -22,6 +22,7 @@
import com.google.common.collect.Iterators;
import java.util.ArrayList;
import java.util.Collections;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class TestNGToAssertJTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestInput.java
index f212564c56..09060a69b1 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestInput.java
@@ -13,6 +13,7 @@
import java.time.ZoneOffset;
import java.time.ZonedDateTime;
import java.time.temporal.ChronoUnit;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class TimeTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestOutput.java
index b4215e599b..215c93fe8c 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/TimeTemplatesTestOutput.java
@@ -13,6 +13,7 @@
import java.time.ZoneOffset;
import java.time.ZonedDateTime;
import java.time.temporal.ChronoUnit;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class TimeTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestInput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestInput.java
index fd33f65edb..323899bb31 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestInput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestInput.java
@@ -11,6 +11,7 @@
import com.google.common.collect.ImmutableSet;
import org.springframework.test.web.reactive.server.WebTestClient;
import org.springframework.web.reactive.function.client.WebClient;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class WebClientTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestOutput.java b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestOutput.java
index 4f3685963d..9e0d57831d 100644
--- a/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestOutput.java
+++ b/error-prone-contrib/src/test/resources/tech/picnic/errorprone/refastertemplates/WebClientTemplatesTestOutput.java
@@ -11,6 +11,7 @@
import com.google.common.collect.ImmutableSet;
import org.springframework.test.web.reactive.server.WebTestClient;
import org.springframework.web.reactive.function.client.WebClient;
+import tech.picnic.errorprone.refaster.test.RefasterTemplateTestCase;
final class WebClientTemplatesTest implements RefasterTemplateTestCase {
@Override
diff --git a/pom.xml b/pom.xml
index cdc945dbdd..123f638701 100644
--- a/pom.xml
+++ b/pom.xml
@@ -41,7 +41,9 @@
error-prone-contrib
refaster-compiler
+ refaster-runner
refaster-support
+ refaster-test-support
@@ -196,11 +198,21 @@
refaster-compiler
${project.version}