File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ version := "1.1.1"
1010isSnapshot := true
1111
1212netLogoClassManager := " org.nlogo.extensions.array.ArrayExtension"
13- netLogoVersion := " 6.2.2"
13+ netLogoVersion := " 6.2.2-2f9fab6 "
1414
1515javaSource in Compile := baseDirectory.value / " src" / " main"
1616scalaSource in Test := baseDirectory.value / " src" / " test"
Original file line number Diff line number Diff line change 11// (C) Uri Wilensky. https://github.com/NetLogo/Python-Extension
22
3- package org .nlogo .extensions .py
3+ package org .nlogo .extensions .array
4+
5+ import org .scalatest .BeforeAndAfterAll
46
57import java .io .File
68import org .nlogo .headless .TestLanguage
@@ -10,6 +12,17 @@ object Tests {
1012 val testFiles = testFileNames.map( (f) => (new File (f)).getCanonicalFile )
1113}
1214
13- class Tests extends TestLanguage (Tests .testFiles) {
15+ class Tests extends TestLanguage (Tests .testFiles) with BeforeAndAfterAll {
1416 System .setProperty(" org.nlogo.preferHeadless" , " true" )
17+
18+ override def afterAll () {
19+ val file = new File (" tmp/array" )
20+ def deleteRec (f : File ) {
21+ if (f.isDirectory) {
22+ f.listFiles().foreach(deleteRec)
23+ }
24+ f.delete()
25+ }
26+ deleteRec(file)
27+ }
1528}
Original file line number Diff line number Diff line change 11ArraysBug716a
22 extensions [array]
33 globals [glob1 glob2]
4- O> __mkdir "tmp/ImportWorld "
4+ O> __mkdir "tmp/array "
55 O> set glob1 array:from-list [1 2]
6- O> set glob2 (word "tmp/ImportWorld /test-file-" __nano-time ".csv")
6+ O> set glob2 (word "tmp/array /test-file-" __nano-time ".csv")
77 O> export-world glob2
88 O> set glob1 0
99 O> import-world glob2
@@ -13,9 +13,9 @@ ArraysBug716a
1313ArraysBug716b
1414 extensions [array]
1515 globals [glob1 glob2]
16- O> __mkdir "tmp/ImportWorld "
16+ O> __mkdir "tmp/array "
1717 O> set glob1 (list array:from-list [1 2] array:from-list [3 4])
18- O> set glob2 (word "tmp/ImportWorld /test-file-" __nano-time ".csv")
18+ O> set glob2 (word "tmp/array /test-file-" __nano-time ".csv")
1919 O> export-world glob2
2020 O> set glob1 0
2121 O> import-world glob2
You can’t perform that action at this time.
0 commit comments