Random testing time-outs independent of exercise

Hi, more or less just as heads up here.

I’m traversing through the Scala exercises … and lately I’ve run into Test timeouts… with solutions submitted via the client. Trying the exact same in the online editor sometime returns success and other times also times-out. kind-of randomly.

I do my solutions in Scala 3, and only seldom alter the build.sbt… I wonder if there is some issue in getting you compiler/testengine up and running or something…?

Thanks for a beautiful concept, I plan to do the Haskell, Cobol and Fortran after the Scala Path :slight_smile:
/Dan

I’m trying to look into the scala-test-runner, but the test-fails on the two last testcases with null-exceptions (I think it tries to find these files:

results_file="${output_dir}/results.json"
build_log_file="${output_dir}/build.log"
runner_log_file="${output_dir}/runner.log"

And if they are not present it fails with a nullPointerexception in the mapping method in ApplicationSpec.scala line 76 …

Actually the call to toExercismJSON with testResultsFiles as null in the testcase is doomed to fail, as you are trying to map over a null …

def toExercismJSON(
    buildLogFilePath: String,
    testResultsFiles: List[File],
  ): JSONObject =
    val baseObject   = new JSONObject().put("version", 2)
    val errorMessage = findErrorsInLog(buildLogFilePath)

    if errorMessage.nonEmpty then
      baseObject
        .put("status", "error")
        .put("message", errorMessage)
    else
      val (failuresCount, testCases) = testResultsFiles
        .map(getTestSuiteObject)