Test classes renamed to reflect what's happening in the tests
This commit is contained in:
+1
-1
@@ -51,7 +51,7 @@ import java.util.List;
|
|||||||
/**
|
/**
|
||||||
* @author abreslav
|
* @author abreslav
|
||||||
*/
|
*/
|
||||||
public abstract class AbstractLazyResolveComparingTest {
|
public abstract class AbstractLazyResolveNamespaceComparingTest {
|
||||||
private final Disposable rootDisposable = new Disposable() {
|
private final Disposable rootDisposable = new Disposable() {
|
||||||
@Override
|
@Override
|
||||||
public void dispose() {
|
public void dispose() {
|
||||||
+11
-11
@@ -25,15 +25,15 @@ import java.lang.reflect.Method;
|
|||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
/* This class is generated by LazyResolveComparingTestGenerator. DO NOT MODIFY MANUALLY */
|
/* This class is generated by LazyResolveNamespaceComparingTestGenerator. DO NOT MODIFY MANUALLY */
|
||||||
@RunWith(Suite.class)
|
@RunWith(Suite.class)
|
||||||
@Suite.SuiteClasses({
|
@Suite.SuiteClasses({
|
||||||
LazyResolveComparingTestGenerated.ReadKotlinBinaryClass.class,
|
LazyResolveNamespaceComparingTestGenerated.ReadKotlinBinaryClass.class,
|
||||||
LazyResolveComparingTestGenerated.ReadJavaBinaryClass.class,
|
LazyResolveNamespaceComparingTestGenerated.ReadJavaBinaryClass.class,
|
||||||
LazyResolveComparingTestGenerated.LazyResolve.class
|
LazyResolveNamespaceComparingTestGenerated.LazyResolve.class
|
||||||
})
|
})
|
||||||
public class LazyResolveComparingTestGenerated {
|
public class LazyResolveNamespaceComparingTestGenerated {
|
||||||
public static class ReadKotlinBinaryClass extends AbstractLazyResolveComparingTest {
|
public static class ReadKotlinBinaryClass extends AbstractLazyResolveNamespaceComparingTest {
|
||||||
@Test
|
@Test
|
||||||
public void allTestsPresentInReadKotlinBinaryClass() throws Exception {
|
public void allTestsPresentInReadKotlinBinaryClass() throws Exception {
|
||||||
allTestsPresent(ReadKotlinBinaryClass.class, new File("compiler/testData/readKotlinBinaryClass"), true);
|
allTestsPresent(ReadKotlinBinaryClass.class, new File("compiler/testData/readKotlinBinaryClass"), true);
|
||||||
@@ -710,14 +710,14 @@ public class LazyResolveComparingTestGenerated {
|
|||||||
else {
|
else {
|
||||||
String name = file.getName();
|
String name = file.getName();
|
||||||
if (name.endsWith(".kt") && !methodNames.contains("test" + name.toLowerCase())) {
|
if (name.endsWith(".kt") && !methodNames.contains("test" + name.toLowerCase())) {
|
||||||
Assert.fail("Test data file missing from the generated test class: " + file + "\nPlease re-run the generator: LazyResolveComparingTestGenerator");
|
Assert.fail("Test data file missing from the generated test class: " + file + "\nPlease re-run the generator: LazyResolveNamespaceComparingTestGenerator");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class ReadJavaBinaryClass extends AbstractLazyResolveComparingTest {
|
public static class ReadJavaBinaryClass extends AbstractLazyResolveNamespaceComparingTest {
|
||||||
@Test
|
@Test
|
||||||
public void allTestsPresentInReadJavaBinaryClass() throws Exception {
|
public void allTestsPresentInReadJavaBinaryClass() throws Exception {
|
||||||
allTestsPresent(ReadJavaBinaryClass.class, new File("compiler/testData/readJavaBinaryClass"), true);
|
allTestsPresent(ReadJavaBinaryClass.class, new File("compiler/testData/readJavaBinaryClass"), true);
|
||||||
@@ -964,14 +964,14 @@ public class LazyResolveComparingTestGenerated {
|
|||||||
else {
|
else {
|
||||||
String name = file.getName();
|
String name = file.getName();
|
||||||
if (name.endsWith(".kt") && !methodNames.contains("test" + name.toLowerCase())) {
|
if (name.endsWith(".kt") && !methodNames.contains("test" + name.toLowerCase())) {
|
||||||
Assert.fail("Test data file missing from the generated test class: " + file + "\nPlease re-run the generator: LazyResolveComparingTestGenerator");
|
Assert.fail("Test data file missing from the generated test class: " + file + "\nPlease re-run the generator: LazyResolveNamespaceComparingTestGenerator");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class LazyResolve extends AbstractLazyResolveComparingTest {
|
public static class LazyResolve extends AbstractLazyResolveNamespaceComparingTest {
|
||||||
@Test
|
@Test
|
||||||
public void allTestsPresentInLazyResolve() throws Exception {
|
public void allTestsPresentInLazyResolve() throws Exception {
|
||||||
allTestsPresent(LazyResolve.class, new File("compiler/testData/lazyResolve"), true);
|
allTestsPresent(LazyResolve.class, new File("compiler/testData/lazyResolve"), true);
|
||||||
@@ -1003,7 +1003,7 @@ public class LazyResolveComparingTestGenerated {
|
|||||||
else {
|
else {
|
||||||
String name = file.getName();
|
String name = file.getName();
|
||||||
if (name.endsWith(".kt") && !methodNames.contains("test" + name.toLowerCase())) {
|
if (name.endsWith(".kt") && !methodNames.contains("test" + name.toLowerCase())) {
|
||||||
Assert.fail("Test data file missing from the generated test class: " + file + "\nPlease re-run the generator: LazyResolveComparingTestGenerator");
|
Assert.fail("Test data file missing from the generated test class: " + file + "\nPlease re-run the generator: LazyResolveNamespaceComparingTestGenerator");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
+5
-5
@@ -26,16 +26,16 @@ import java.util.Arrays;
|
|||||||
/**
|
/**
|
||||||
* @author abreslav
|
* @author abreslav
|
||||||
*/
|
*/
|
||||||
public class LazyResolveComparingTestGenerator {
|
public class LazyResolveNamespaceComparingTestGenerator {
|
||||||
public static void main(String[] args) throws IOException {
|
public static void main(String[] args) throws IOException {
|
||||||
String testDataFileExtension = "kt";
|
String testDataFileExtension = "kt";
|
||||||
new TestGenerator(
|
new TestGenerator(
|
||||||
"compiler/tests/",
|
"compiler/tests/",
|
||||||
testDataFileExtension,
|
testDataFileExtension,
|
||||||
"org.jetbrains.jet.lang.resolve.lazy",
|
"org.jetbrains.jet.lang.resolve.lazy",
|
||||||
"LazyResolveComparingTestGenerated",
|
"LazyResolveNamespaceComparingTestGenerated",
|
||||||
"org.jetbrains.jet.lang.resolve.lazy",
|
"org.jetbrains.jet.lang.resolve.lazy",
|
||||||
"AbstractLazyResolveComparingTest",
|
"AbstractLazyResolveNamespaceComparingTest",
|
||||||
Arrays.asList(
|
Arrays.asList(
|
||||||
new TestDataSource(new File("compiler/testData/readKotlinBinaryClass"),
|
new TestDataSource(new File("compiler/testData/readKotlinBinaryClass"),
|
||||||
true,
|
true,
|
||||||
@@ -50,9 +50,9 @@ public class LazyResolveComparingTestGenerator {
|
|||||||
TestGenerator.filterFilesByExtension(testDataFileExtension),
|
TestGenerator.filterFilesByExtension(testDataFileExtension),
|
||||||
"doTest")
|
"doTest")
|
||||||
),
|
),
|
||||||
"LazyResolveComparingTestGenerator"
|
"LazyResolveNamespaceComparingTestGenerator"
|
||||||
).generateAndSave();
|
).generateAndSave();
|
||||||
}
|
}
|
||||||
|
|
||||||
private LazyResolveComparingTestGenerator() {}
|
private LazyResolveNamespaceComparingTestGenerator() {}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user