Created
August 23, 2014 04:25
-
-
Save qiemem/5a0360c30d27416b0913 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| val wolfSheep = Source.fromFile("public/modelslib/Sample Models/Biology/Wolf Sheep Predation.nlogo").mkString | |
| val wsModelV = CompiledModel.fromNlogoContents(wolfSheep) | |
| val wsModel = wsModelV valueOr { e => fail(modelShouldHaveCompiled(e)) } | |
| private val modelShouldHaveCompiled = (failures: NonEmptyList[CompilerException]) => | |
| s"""|Model should have compiled but failed with the following messages: | |
| |${failures.stream.mkString("\n")}""".stripMargin |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment