Skip to content

Commit d6914e8

Browse files
committed
DO NOT MERGE. Debugging Jenkins file encoding error
1 parent af0cec0 commit d6914e8

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

test/test/CompilerTest.scala

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,16 @@ abstract class CompilerTest extends DottyTest {
255255
processFileDir(sourceFile, { sf =>
256256
if (extensionsToCopy.contains(sf.extension)) {
257257
dest.parent.jfile.mkdirs
258-
FileManager.copyFile(sourceFile.jfile, dest.jfile)
258+
println("copying " + sf.toString + " with default codec " + sf.creationCodec)
259+
val contents = try { sf.slurp } catch {
260+
case e: Throwable => println("==================\n=======BOOM=======\n==================\nfailed slurping file " + sf.toString); ""
261+
}
262+
dest.toFile.writeAll("/* ==========================================\n",
263+
" * ========= AUTOMATICALLY GENERATED ========\n",
264+
" * ========= DO NOT EDIT THIS FILE ==========\n",
265+
" * ==========================================\n",
266+
" * Original: " + sf.toString + " */\n\n",
267+
contents)
259268
} else {
260269
log(s"WARNING: ignoring $sf")
261270
}

0 commit comments

Comments
 (0)