Throw exception if initial build has failed in IC tests
This commit is contained in:
+4
-1
@@ -52,7 +52,10 @@ abstract class IncrementalCompilerRunnerTestBase<Args : CommonCompilerArguments>
|
|||||||
val sourceRoots = listOf(srcDir)
|
val sourceRoots = listOf(srcDir)
|
||||||
val args = createCompilerArguments(outDir, testDir)
|
val args = createCompilerArguments(outDir, testDir)
|
||||||
// initial build
|
// initial build
|
||||||
make(cacheDir, sourceRoots, args)
|
val (_, _, errors) = make(cacheDir, sourceRoots, args)
|
||||||
|
if (errors.isNotEmpty()) {
|
||||||
|
throw IllegalStateException("Initial build failed: \n${errors.joinToString("\n")}")
|
||||||
|
}
|
||||||
|
|
||||||
// modifications
|
// modifications
|
||||||
val buildLogFile = buildLogFinder.findBuildLog(testDir) ?: throw IllegalStateException("build log file not found in $workingDir")
|
val buildLogFile = buildLogFinder.findBuildLog(testDir) ?: throw IllegalStateException("build log file not found in $workingDir")
|
||||||
|
|||||||
Reference in New Issue
Block a user