-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtests.txt
More file actions
executable file
·176 lines (169 loc) · 6.8 KB
/
Copy pathtests.txt
File metadata and controls
executable file
·176 lines (169 loc) · 6.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
DefaultExperiment
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
bspace:get-variables => ""
bspace:get-repetitions => 1
bspace:get-sequential-run-order => true
bspace:get-metrics => []
bspace:get-run-metrics-every-step => true
bspace:get-run-metrics-condition => ""
bspace:get-pre-experiment-commands => ""
bspace:get-setup-commands => ""
bspace:get-go-commands => ""
bspace:get-stop-condition => ""
bspace:get-post-run-commands => ""
bspace:get-post-experiment-commands => ""
bspace:get-time-limit => 0
bspace:get-spreadsheet => ""
bspace:get-table => ""
bspace:get-stats => ""
bspace:get-lists => ""
bspace:get-mirror-headless-output => false
SetAllParameters
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-variables [ "[ \"test\" 0 2 10 ]" ]
O> bspace:set-repetitions 5
O> bspace:set-sequential-run-order false
O> bspace:set-metrics [ count turtles ]
O> bspace:set-run-metrics-every-step false
O> bspace:set-run-metrics-condition [ ticks mod 5 = 0 ]
O> bspace:set-pre-experiment-commands [ print "before" ]
O> bspace:set-setup-commands [ print "setup" ]
O> bspace:set-go-commands [ print "go" ]
O> bspace:set-stop-condition [ ticks >= 42]
O> bspace:set-post-run-commands [ print "end" ]
O> bspace:set-post-experiment-commands [ print "after" ]
O> bspace:set-time-limit 100
O> bspace:set-spreadsheet "spreadsheet"
O> bspace:set-table "table"
O> bspace:set-stats "stats"
O> bspace:set-lists "lists"
O> bspace:set-mirror-headless-output true
bspace:get-variables => "[\"test\" 0 2 10]"
bspace:get-repetitions => 5
bspace:get-sequential-run-order => false
bspace:get-metrics => ["count turtles"]
bspace:get-run-metrics-every-step => false
bspace:get-run-metrics-condition => "ticks mod 5 = 0"
bspace:get-pre-experiment-commands => "print \"before\""
bspace:get-setup-commands => "print \"setup\""
bspace:get-go-commands => "print \"go\""
bspace:get-stop-condition => "ticks >= 42"
bspace:get-post-run-commands => "print \"end\""
bspace:get-post-experiment-commands => "print \"after\""
bspace:get-time-limit => 100
bspace:get-spreadsheet => "spreadsheet"
bspace:get-table => "table"
bspace:get-stats => "stats"
bspace:get-lists => "lists"
bspace:get-mirror-headless-output => true
OverwriteSameName
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-time-limit 5
bspace:get-time-limit => 5
O> bspace:create-experiment "test" false => ERROR Extension exception: An experiment already exists with the name "test".
O> bspace:create-experiment "test" true
bspace:get-time-limit => 0
OverwriteDifferentName
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-time-limit 5
O> bspace:create-experiment "test2" true
O> bspace:set-current-experiment "test2"
O> bspace:set-time-limit 10
O> bspace:create-experiment "test" false => ERROR Extension exception: An experiment already exists with the name "test".
O> bspace:create-experiment "test2" false => ERROR Extension exception: An experiment already exists with the name "test2".
O> bspace:create-experiment "test" true
bspace:get-time-limit => 10
O> bspace:set-current-experiment "test"
bspace:get-time-limit => 0
ClearExperiments
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:create-experiment "test2" true
bspace:get-experiment-list => ["test" "test2"]
O> bspace:clear-experiments
bspace:get-experiment-list => []
NestedExperiment
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-post-experiment-commands [ bspace:delete-experiment "test3" ]
O> bspace:set-time-limit 1
O> bspace:create-experiment "test2" true
O> bspace:set-current-experiment "test2"
O> bspace:set-pre-experiment-commands [ /
bspace:create-experiment "test3" true /
bspace:set-current-experiment "test" /
bspace:run-experiment /
]
O> bspace:set-time-limit 1
O> bspace:run-experiment
bspace:get-experiment-list => ["test" "test2"]
PreventRecursion
extensions [ bspace ]
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-pre-experiment-commands [ bspace:run-experiment ]
O> bspace:set-time-limit 10
O> bspace:run-experiment => ERROR Extension exception: Cannot run an experiment recursively.
O> bspace:clear-experiments
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-post-experiment-commands [ /
bspace:create-experiment "test2" true /
bspace:set-current-experiment "test2" /
bspace:set-post-experiment-commands [ /
bspace:set-current-experiment "test" /
bspace:run-experiment /
] /
bspace:set-time-limit 10 /
bspace:run-experiment /
]
O> bspace:set-time-limit 10
O> bspace:run-experiment => ERROR Extension exception: Cannot run an experiment recursively.
ExportImport
extensions [ bspace ]
globals [ path ]
O> __mkdir "tmp/bspace"
O> set path (word "tmp/bspace/test_bspace_" __nano-time ".xml")
O> bspace:create-experiment "test" true
O> bspace:set-current-experiment "test"
O> bspace:set-variables [ "[ \"test\" 0 2 10 ]" ]
O> bspace:set-repetitions 5
O> bspace:set-sequential-run-order false
O> bspace:set-metrics [ count turtles ]
O> bspace:set-run-metrics-every-step false
O> bspace:set-run-metrics-condition [ ticks mod 5 = 0 ]
O> bspace:set-pre-experiment-commands [ print "before" ]
O> bspace:set-setup-commands [ print "setup" ]
O> bspace:set-go-commands [ print "go" ]
O> bspace:set-stop-condition [ ticks >= 42]
O> bspace:set-post-run-commands [ print "end" ]
O> bspace:set-post-experiment-commands [ print "after" ]
O> bspace:set-time-limit 100
O> bspace:export-experiment path true
O> bspace:import-experiments path => ERROR Extension exception: An experiment already exists with the name "test".
O> bspace:clear-experiments
O> bspace:import-experiments path
O> bspace:set-current-experiment "test"
bspace:get-experiment-list => ["test"]
bspace:get-variables => "[\"test\" 0 2 10]"
bspace:get-repetitions => 5
bspace:get-sequential-run-order => false
bspace:get-metrics => ["count turtles"]
bspace:get-run-metrics-every-step => false
bspace:get-run-metrics-condition => "ticks mod 5 = 0"
bspace:get-pre-experiment-commands => "print \"before\""
bspace:get-setup-commands => "print \"setup\""
bspace:get-go-commands => "print \"go\""
bspace:get-stop-condition => "ticks >= 42"
bspace:get-post-run-commands => "print \"end\""
bspace:get-post-experiment-commands => "print \"after\""
bspace:get-time-limit => 100