Skip to content

Commit 863035c

Browse files
committed
Updated aggregator to create parent dirs
1 parent 809db4e commit 863035c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scalac-scoverage-plugin/src/main/scala/scoverage/IOUtils.scala

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ object IOUtils {
4040
}
4141

4242
/**
43-
* @return the measurement file for the current thread.
43+
* Returns the measurement file for the current thread.
4444
*/
4545
def measurementFile(dataDir: File): File = measurementFile(dataDir.getAbsolutePath)
4646
def measurementFile(dataDir: String): File = new File(dataDir, Constants.MeasurementsPrefix + Thread.currentThread.getId)
@@ -68,6 +68,7 @@ object IOUtils {
6868
if (files.size > 0) {
6969
val nodes = files.map(xml.XML.loadFile)
7070
val aggregated = ScoverageXmlMerger.merge(nodes)
71+
targetDir.mkdirs()
7172
val outFile = new File(targetDir, Constants.XMLReportFilename)
7273
writeToFile(outFile, aggregated.toString)
7374
}

0 commit comments

Comments
 (0)