Skip to content

Commit ad532dd

Browse files
authored
Merge pull request #438 from NetLogo/fixing-failing-tests
Fixing failing tests
2 parents 0aa17db + 39408e5 commit ad532dd

32 files changed

Lines changed: 266 additions & 266 deletions

Curricular Models/MaterialSim/MaterialSim Grain Growth.nlogox

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ end
256256
; Copyright 2005 Uri Wilensky.
257257
; See Info tab for full copyright and license.]]></code>
258258
<widgets>
259-
<view x="345" wrappingAllowedX="false" y="5" frameRate="60.0" minPycor="-24" height="464" showTickCounter="true" patchSize="9.4" fontSize="10" wrappingAllowedY="false" width="464" tickCounterLabel="ticks" maxPycor="24" updateMode="1" maxPxcor="24" minPxcor="-24"></view>
259+
<view x="345" wrappingAllowedX="false" y="5" frameRate="60.0" minPycor="-24" height="445" showTickCounter="true" patchSize="9.0" fontSize="9" wrappingAllowedY="false" width="445" tickCounterLabel="ticks" maxPycor="24" updateMode="1" maxPxcor="24" minPxcor="-24"></view>
260260
<note x="30" y="570" backgroundDark="0" fontSize="11" width="139" markdown="false" height="18" textColorDark="-1" textColorLight="-16777216" backgroundLight="0">Run model</note>
261261
<note x="30" y="544" backgroundDark="0" fontSize="11" width="295" markdown="false" height="18" textColorDark="-1" textColorLight="-16777216" backgroundLight="0">_____________________________________________</note>
262262
<note x="5" y="75" backgroundDark="0" fontSize="30" width="25" markdown="false" height="36" textColorDark="-1" textColorLight="-5298144" backgroundLight="0">1</note>

Sample Models/Biology/Disease Solo.nlogox

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ end
161161
; Copyright 2005 Uri Wilensky.
162162
; See Info tab for full copyright and license.]]></code>
163163
<widgets>
164-
<view x="281" wrappingAllowedX="false" y="10" frameRate="10.0" minPycor="-12" height="475" showTickCounter="true" patchSize="19.0" fontSize="10" wrappingAllowedY="false" width="399" tickCounterLabel="ticks" maxPycor="12" updateMode="1" maxPxcor="10" minPxcor="-10"></view>
164+
<view x="281" wrappingAllowedX="false" y="10" frameRate="10.0" minPycor="-12" height="479" showTickCounter="true" patchSize="19.0" fontSize="10" wrappingAllowedY="false" width="403" tickCounterLabel="ticks" maxPycor="12" updateMode="1" maxPxcor="10" minPxcor="-10"></view>
165165
<button x="24" y="65" height="35" disableUntilTicks="false" forever="false" kind="Observer" width="102" display="setup/clear">setup-clear</button>
166166
<button x="24" y="145" height="35" disableUntilTicks="true" forever="true" kind="Observer" width="102">go</button>
167167
<button x="24" y="105" height="35" disableUntilTicks="false" forever="false" kind="Observer" width="102" display="setup/keep">setup-keep</button>
@@ -188,8 +188,8 @@ set-plot-pen-color item (run-number mod 5)
188188
<button x="845" actionKey="L" y="80" height="35" disableUntilTicks="true" forever="false" kind="Observer" width="63" display="right">move 90</button>
189189
<button x="790" actionKey="I" y="40" height="35" disableUntilTicks="true" forever="false" kind="Observer" width="69" display="up">move 0</button>
190190
<button x="130" y="145" height="35" disableUntilTicks="true" forever="false" kind="Observer" width="102">infect</button>
191-
<switch x="699" y="445" height="37" on="false" variable="chase?" width="103" display="chase?"></switch>
192-
<switch x="699" y="405" height="37" on="false" variable="avoid?" width="103" display="avoid?"></switch>
191+
<switch x="699" y="445" height="40" on="false" variable="chase?" width="103" display="chase?"></switch>
192+
<switch x="699" y="405" height="40" on="false" variable="avoid?" width="103" display="avoid?"></switch>
193193
<note x="695" y="375" backgroundDark="0" fontSize="11" width="150" markdown="false" height="24" textColorDark="-1" textColorLight="-16777216" backgroundLight="0">androids:</note>
194194
</widgets>
195195
<info><![CDATA[## WHAT IS IT?

Sample Models/Biology/Evolution/Baldwin Effect.nlogox

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ end
263263
; Copyright 2023 Uri Wilensky.
264264
; See Info tab for full copyright and license.]]></code>
265265
<widgets>
266-
<view x="715" wrappingAllowedX="false" y="7" frameRate="30.0" minPycor="-5" height="555" showTickCounter="true" patchSize="5.0" fontSize="10" wrappingAllowedY="false" width="405" tickCounterLabel="ticks" maxPycor="105" updateMode="1" maxPxcor="40" minPxcor="-40"></view>
266+
<view x="720" wrappingAllowedX="false" y="10" frameRate="30.0" minPycor="-5" height="559" showTickCounter="true" patchSize="5.0" fontSize="10" wrappingAllowedY="false" width="409" tickCounterLabel="ticks" maxPycor="105" updateMode="1" maxPxcor="40" minPxcor="-40"></view>
267267
<slider x="20" step="1" y="7" max="500" width="250" display="num-pop" height="50" min="1" direction="Horizontal" default="200.0" variable="num-pop"></slider>
268268
<slider x="20" step="1" y="60" max="100" width="250" display="gene-length" height="50" min="1" direction="Horizontal" default="30.0" variable="gene-length"></slider>
269269
<slider x="20" step="0.01" y="115" max="1" width="250" display="plasticity" height="50" min="0" direction="Horizontal" default="0.5" variable="plasticity"></slider>
@@ -272,35 +272,35 @@ end
272272
<slider x="20" step="1" y="215" max="100" width="250" display="num-trials" height="50" min="1" direction="Horizontal" default="20.0" variable="num-trials"></slider>
273273
<slider x="20" step="0.1" y="270" max="10" width="250" display="mutation-rate" height="50" min="0" direction="Horizontal" default="5.0" variable="mutation-rate" units="E-4"></slider>
274274
<slider x="20" step="0.01" y="325" max="1" width="250" display="smoothness" height="50" min="0" direction="Horizontal" default="0.15" variable="smoothness"></slider>
275-
<plot x="369" autoPlotX="true" yMax="100.0" autoPlotY="true" yAxis="% Correct Alleles" y="385" xMin="0.0" height="225" legend="true" xMax="10.0" yMin="0.0" width="345" xAxis="Generations" display="Percentage of Correct Alleles">
275+
<plot x="20" autoPlotX="true" yMax="100.0" autoPlotY="true" yAxis="% Plastic Alleles" y="385" xMin="0.0" height="225" legend="true" xMax="10.0" yMin="0.0" width="340" xAxis="Generations" display="Percentage of Plastic Alleles">
276276
<setup></setup>
277277
<update></update>
278278
<pen interval="1.0" mode="0" display="Smart Learners" color="-13345367" legend="true">
279279
<setup></setup>
280-
<update>plot percentage-correct-alleles smart-learners</update>
280+
<update>plot percentage-plastic-alleles smart-learners</update>
281281
</pen>
282282
<pen interval="1.0" mode="0" display="Random Learners" color="-2674135" legend="true">
283283
<setup></setup>
284-
<update>plot percentage-correct-alleles random-learners</update>
285-
</pen>
286-
<pen interval="1.0" mode="0" display="Non-Learners" color="-7500403" legend="true">
287-
<setup></setup>
288-
<update>plot percentage-correct-alleles non-learners</update>
284+
<update>plot percentage-plastic-alleles random-learners</update>
289285
</pen>
290286
</plot>
291-
<plot x="20" autoPlotX="true" yMax="100.0" autoPlotY="true" yAxis="% Plastic Alleles" y="385" xMin="0.0" height="225" legend="true" xMax="10.0" yMin="0.0" width="340" xAxis="Generations" display="Percentage of Plastic Alleles">
287+
<plot x="365" autoPlotX="true" yMax="100.0" autoPlotY="true" yAxis="% Correct Alleles" y="385" xMin="0.0" height="225" legend="true" xMax="10.0" yMin="0.0" width="345" xAxis="Generations" display="Percentage of Correct Alleles">
292288
<setup></setup>
293289
<update></update>
294290
<pen interval="1.0" mode="0" display="Smart Learners" color="-13345367" legend="true">
295291
<setup></setup>
296-
<update>plot percentage-plastic-alleles smart-learners</update>
292+
<update>plot percentage-correct-alleles smart-learners</update>
297293
</pen>
298294
<pen interval="1.0" mode="0" display="Random Learners" color="-2674135" legend="true">
299295
<setup></setup>
300-
<update>plot percentage-plastic-alleles random-learners</update>
296+
<update>plot percentage-correct-alleles random-learners</update>
297+
</pen>
298+
<pen interval="1.0" mode="0" display="Non-Learners" color="-7500403" legend="true">
299+
<setup></setup>
300+
<update>plot percentage-correct-alleles non-learners</update>
301301
</pen>
302302
</plot>
303-
<plot x="280" autoPlotX="true" yMax="1.0" autoPlotY="true" yAxis="Average Fitness" y="7" xMin="0.0" height="370" legend="true" xMax="10.0" yMin="0.4" width="429" xAxis="Generations" display="Average Fitness">
303+
<plot x="280" autoPlotX="true" yMax="1.0" autoPlotY="true" yAxis="Average Fitness" y="5" xMin="0.0" height="370" legend="true" xMax="10.0" yMin="0.4" width="429" xAxis="Generations" display="Average Fitness">
304304
<setup></setup>
305305
<update></update>
306306
<pen interval="1.0" mode="0" display="Smart Learners" color="-13345367" legend="true">

Sample Models/Biology/Evolution/Echo.nlogox

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -226,16 +226,8 @@ end
226226
; Copyright 2005 Uri Wilensky.
227227
; See Info tab for full copyright and license.]]></code>
228228
<widgets>
229-
<view x="275" wrappingAllowedX="true" y="7" frameRate="30.0" minPycor="-5" height="444" showTickCounter="true" patchSize="44.1" fontSize="10" wrappingAllowedY="true" width="444" tickCounterLabel="ticks" maxPycor="5" updateMode="1" maxPxcor="5" minPxcor="-5"></view>
230-
<slider x="12" step="25" y="23" max="1000" width="250" display="init-num-creatures" height="50" min="25" direction="Horizontal" default="400.0" variable="init-num-creatures"></slider>
231-
<switch x="43" y="135" height="37" on="false" variable="selective-mating?" width="185" display="selective-mating?"></switch>
232-
<slider x="8" step="0.1" y="335" max="10" width="250" display="mutation-rate" height="50" min="0" direction="Horizontal" default="0.0" variable="mutation-rate" units="%"></slider>
233-
<slider x="8" step="0.1" y="284" max="5" width="250" display="replenish-speed" height="50" min="0" direction="Horizontal" default="1.0" variable="replenish-speed"></slider>
234-
<slider x="8" step="0.1" y="230" max="10" width="250" display="replicate-chance" height="50" min="0" direction="Horizontal" default="0.0" variable="replicate-chance" units="%"></slider>
235-
<slider x="10" step="1" y="175" max="6" width="250" display="mating-selectivity" height="50" min="-6" direction="Horizontal" default="0.0" variable="mating-selectivity"></slider>
236-
<button x="35" y="85" height="40" disableUntilTicks="false" forever="false" kind="Observer" width="100">setup</button>
237-
<button x="140" y="85" height="40" disableUntilTicks="true" forever="true" kind="Observer" width="95">go</button>
238-
<plot x="730" autoPlotX="true" yMax="1.0" autoPlotY="true" y="7" xMin="0.0" height="180" legend="true" xMax="50.0" yMin="0.0" width="605" xAxis="ticks" display="Populations">
229+
<view x="275" wrappingAllowedX="true" y="7" frameRate="30.0" minPycor="-5" height="488" showTickCounter="true" patchSize="44.0" fontSize="10" wrappingAllowedY="true" width="488" tickCounterLabel="ticks" maxPycor="5" updateMode="1" maxPxcor="5" minPxcor="-5"></view>
230+
<plot x="775" autoPlotX="true" yMax="1.0" autoPlotY="true" y="5" xMin="0.0" height="180" legend="true" xMax="50.0" yMin="0.0" width="610" xAxis="ticks" display="Populations">
239231
<setup></setup>
240232
<update><![CDATA[set-current-plot-pen "largest species"
241233
let biggest-mating modes [mating] of turtles
@@ -262,7 +254,7 @@ ifelse (length biggest-mating > 0)
262254
<update></update>
263255
</pen>
264256
</plot>
265-
<plot x="735" autoPlotX="true" yMax="1.0" autoPlotY="true" y="365" xMin="0.0" height="195" legend="true" xMax="50.0" yMin="0.0" width="600" xAxis="ticks" display="Speciation">
257+
<plot x="775" autoPlotX="true" yMax="1.0" autoPlotY="true" y="360" xMin="0.0" height="195" legend="true" xMax="50.0" yMin="0.0" width="610" xAxis="ticks" display="Speciation">
266258
<setup></setup>
267259
<update></update>
268260
<pen interval="1.0" mode="0" display="species" color="-2674135" legend="true">
@@ -278,23 +270,23 @@ ifelse (length biggest-mating > 0)
278270
<update>plot length remove-duplicates [defense] of turtles</update>
279271
</pen>
280272
</plot>
281-
<plot x="935" autoPlotX="true" yMax="1.0" autoPlotY="true" y="195" xMin="0.0" height="165" legend="false" xMax="39.0" yMin="0.0" width="200" display="Defense Tags">
273+
<plot x="775" autoPlotX="true" yMax="1.0" autoPlotY="true" y="190" xMin="0.0" height="165" legend="false" xMax="39.0" yMin="0.0" width="200" display="Offense Tags">
282274
<setup>set-plot-x-range 0 length all-tags</setup>
283275
<update></update>
284276
<pen interval="1.0" mode="1" display="default" color="-16777216" legend="true">
285277
<setup></setup>
286-
<update>histogram [position defense all-tags] of turtles</update>
278+
<update>histogram [position offense all-tags] of turtles</update>
287279
</pen>
288280
</plot>
289-
<plot x="733" autoPlotX="true" yMax="1.0" autoPlotY="true" y="195" xMin="0.0" height="165" legend="false" xMax="39.0" yMin="0.0" width="200" display="Offense Tags">
281+
<plot x="980" autoPlotX="true" yMax="1.0" autoPlotY="true" y="190" xMin="0.0" height="165" legend="false" xMax="39.0" yMin="0.0" width="200" display="Defense Tags">
290282
<setup>set-plot-x-range 0 length all-tags</setup>
291283
<update></update>
292284
<pen interval="1.0" mode="1" display="default" color="-16777216" legend="true">
293285
<setup></setup>
294-
<update>histogram [position offense all-tags] of turtles</update>
286+
<update>histogram [position defense all-tags] of turtles</update>
295287
</pen>
296288
</plot>
297-
<plot x="1137" autoPlotX="true" yMax="1.0" autoPlotY="true" y="195" xMin="0.0" height="165" legend="false" xMax="100.0" yMin="0.0" width="200" display="Species Counts">
289+
<plot x="1185" autoPlotX="true" yMax="1.0" autoPlotY="true" y="190" xMin="0.0" height="165" legend="false" xMax="100.0" yMin="0.0" width="200" display="Species Counts">
298290
<setup>set-plot-x-range 0 length all-tags</setup>
299291
<update></update>
300292
<pen interval="1.0" mode="1" display="default" color="-16777216" legend="true">
@@ -308,7 +300,15 @@ foreach all-tags [ the-tag ->
308300
]]]></update>
309301
</pen>
310302
</plot>
311-
<monitor x="1230" precision="17" y="125" height="60" fontSize="11" width="100" display="total pop.">count turtles</monitor>
303+
<slider x="10" step="25" y="10" max="1000" width="250" display="init-num-creatures" height="50" min="25" direction="Horizontal" default="400.0" variable="init-num-creatures"></slider>
304+
<button x="35" y="65" height="40" disableUntilTicks="false" forever="false" kind="Observer" width="100">setup</button>
305+
<button x="140" y="65" height="40" disableUntilTicks="true" forever="true" kind="Observer" width="95">go</button>
306+
<switch x="45" y="110" height="40" on="false" variable="selective-mating?" width="185" display="selective-mating?"></switch>
307+
<slider x="10" step="1" y="155" max="6" width="250" display="mating-selectivity" height="50" min="-6" direction="Horizontal" default="0.0" variable="mating-selectivity"></slider>
308+
<slider x="10" step="0.1" y="210" max="10" width="250" display="replicate-chance" height="50" min="0" direction="Horizontal" default="0.0" variable="replicate-chance" units="%"></slider>
309+
<slider x="10" step="0.1" y="265" max="5" width="250" display="replenish-speed" height="50" min="0" direction="Horizontal" default="1.0" variable="replenish-speed"></slider>
310+
<slider x="10" step="0.1" y="320" max="10" width="250" display="mutation-rate" height="50" min="0" direction="Horizontal" default="0.0" variable="mutation-rate" units="%"></slider>
311+
<monitor x="1285" precision="17" y="120" height="60" fontSize="11" width="100" display="total pop.">count turtles</monitor>
312312
</widgets>
313313
<info><![CDATA[## WHAT IS IT?
314314

Sample Models/Biology/Evolution/Genetic Drift/GenDrift T interact.nlogox

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ end
9696
; Copyright 1997 Uri Wilensky.
9797
; See Info tab for full copyright and license.]]></code>
9898
<widgets>
99-
<view x="455" wrappingAllowedX="true" y="10" frameRate="30.0" minPycor="-17" height="455" showTickCounter="true" patchSize="13.0" fontSize="10" wrappingAllowedY="true" width="455" tickCounterLabel="ticks" maxPycor="17" updateMode="1" maxPxcor="17" minPxcor="-17"></view>
99+
<view x="455" wrappingAllowedX="true" y="10" frameRate="30.0" minPycor="-17" height="459" showTickCounter="true" patchSize="13.0" fontSize="10" wrappingAllowedY="true" width="459" tickCounterLabel="ticks" maxPycor="17" updateMode="1" maxPxcor="17" minPxcor="-17"></view>
100100
<monitor x="255" precision="2" y="70" height="60" fontSize="11" width="117" display="% most populous">max-percent</monitor>
101101
<plot x="10" autoPlotX="true" yMax="70.0" autoPlotY="true" yAxis="Number" y="135" xMin="0.0" height="223" legend="false" xMax="100.0" yMin="0.0" width="360" xAxis="Time" display="Turtle Populations">
102102
<setup>set-plot-y-range 0 count turtles</setup>

Sample Models/Biology/Evolution/Genetic Drift/GenDrift T reproduce.nlogox

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ end
4444
; Copyright 1997 Uri Wilensky.
4545
; See Info tab for full copyright and license.]]></code>
4646
<widgets>
47-
<view x="400" wrappingAllowedX="true" y="7" frameRate="30.0" minPycor="-22" height="405" showTickCounter="true" patchSize="9.0" fontSize="10" wrappingAllowedY="true" width="405" tickCounterLabel="ticks" maxPycor="22" updateMode="1" maxPxcor="22" minPxcor="-22"></view>
47+
<view x="400" wrappingAllowedX="true" y="7" frameRate="30.0" minPycor="-22" height="409" showTickCounter="true" patchSize="9.0" fontSize="10" wrappingAllowedY="true" width="409" tickCounterLabel="ticks" maxPycor="22" updateMode="1" maxPxcor="22" minPxcor="-22"></view>
4848
<button x="4" y="7" height="50" disableUntilTicks="false" forever="false" kind="Observer" width="75" display="setup">setup</button>
4949
<button x="90" y="7" height="50" disableUntilTicks="true" forever="true" kind="Observer" width="90" display="go">go</button>
5050
<slider x="5" step="1" y="71" max="10" width="250" display="colors" height="50" min="2" direction="Horizontal" default="5.0" variable="colors"></slider>

Sample Models/Biology/Evolution/Vision Evolution.nlogox

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,15 +233,15 @@ end
233233
; Copyright 2018 Uri Wilensky.
234234
; See Info tab for full copyright and license.]]></code>
235235
<widgets>
236-
<view x="760" wrappingAllowedX="true" y="10" frameRate="30.0" minPycor="-50" height="559" showTickCounter="true" patchSize="5.5" fontSize="14" wrappingAllowedY="false" width="559" tickCounterLabel="ticks" maxPycor="50" updateMode="1" maxPxcor="50" minPxcor="-50"></view>
236+
<view x="760" wrappingAllowedX="true" y="10" frameRate="30.0" minPycor="-50" height="509" showTickCounter="true" patchSize="5.0" fontSize="14" wrappingAllowedY="false" width="509" tickCounterLabel="ticks" maxPycor="50" updateMode="1" maxPxcor="50" minPxcor="-50"></view>
237237
<slider x="260" step="1" y="10" max="250" width="250" display="initial-number-food" height="50" min="0" direction="Horizontal" default="80.0" variable="initial-number-food"></slider>
238238
<slider x="5" step="1" y="10" max="250" width="250" display="initial-number-fish" height="50" min="0" direction="Horizontal" default="50.0" variable="initial-number-fish"></slider>
239239
<slider x="5" step="1.0" y="107" max="300.0" width="250" display="energy-gain-from-food" height="50" min="0.0" direction="Horizontal" default="100.0" variable="energy-gain-from-food"></slider>
240240
<slider x="5" step="1" y="159" max="100" width="250" display="food-replenish-rate" height="50" min="0" direction="Horizontal" default="65.0" variable="food-replenish-rate" units="%"></slider>
241241
<slider x="260" step="0.01" y="161" max="1" width="250" display="mutation-rate" height="50" min="0" direction="Horizontal" default="0.1" variable="mutation-rate"></slider>
242242
<slider x="260" step="1" y="109" max="100" width="250" display="reproduction-rate" height="50" min="0" direction="Horizontal" default="35.0" variable="reproduction-rate" units="%"></slider>
243243
<slider x="5" step="0.1" y="211" max="10" width="250" display="eye-cost" height="50" min="0" direction="Horizontal" default="9.0" variable="eye-cost"></slider>
244-
<switch x="300" y="65" height="37" on="true" variable="show-vision?" width="175" display="show-vision?"></switch>
244+
<switch x="300" y="65" height="40" on="true" variable="show-vision?" width="175" display="show-vision?"></switch>
245245
<slider x="260" step="1" y="213" max="10" width="250" display="max-eye-size" height="50" min="1" direction="Horizontal" default="5.0" variable="max-eye-size"></slider>
246246
<button x="45" y="65" height="40" disableUntilTicks="false" forever="false" kind="Observer" width="90" display="setup">setup</button>
247247
<button x="140" y="65" height="40" disableUntilTicks="true" forever="true" kind="Observer" width="85" display="go">go</button>

0 commit comments

Comments
 (0)