JVM: CHECK_BYTECODE_TEST directive + use it in INVOKEDYNAMIC tests

This commit is contained in:
Dmitry Petrov
2021-04-02 16:33:52 +03:00
committed by TeamCityServer
parent ca352c9556
commit 162363a324
119 changed files with 581 additions and 30 deletions
@@ -35,8 +35,14 @@ abstract class AbstractBytecodeTextTest : CodegenTestCase() {
private fun doTestMultiFile(files: List<TestFile>, reportProblems: Boolean) {
val expectedOccurrencesByOutputFile = LinkedHashMap<String, List<OccurrenceInfo>>()
val globalOccurrences = ArrayList<OccurrenceInfo>()
for (file in files) {
readExpectedOccurrencesForMultiFileTest(file.name, file.content, expectedOccurrencesByOutputFile)
readExpectedOccurrencesForMultiFileTest(file.name, file.content, expectedOccurrencesByOutputFile, globalOccurrences)
}
if (globalOccurrences.isNotEmpty()) {
val generatedText = generateToText()
checkGeneratedTextAgainstExpectedOccurrences(generatedText, globalOccurrences, backend, reportProblems, JUnit4Assertions)
}
val generated = generateEachFileToText()