results: regenerate test, mutation (a-l), bench logs

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-08 18:53:12 +01:00
co-authored by Claude Sonnet 5.5
parent 388e901541
commit 0e67331b6c
3 changed files with 356 additions and 81 deletions
+13 -13
View File
@@ -1,17 +1,17 @@
== prototype scene (60 walls, 8 tokens, radius 400, cell 32) ==
1 poly (jittered start positions): n=2000 avg=0.036ms worst=0.121ms
6 polys (one 6-token party): n=500 avg=0.204ms worst=0.264ms
1 poly + cellsTouched (scanline): n=2000 avg=0.049ms worst=0.339ms
6 polys + cellsTouched (scanline): n=300 avg=0.265ms worst=0.353ms
1 poly + cellsTouchedOld (prototype reference): n=500 avg=0.726ms worst=2.365ms
TARGET polygon+cells, prototype scene (prototype baseline 0.451): 0.049 ms vs <= 0.451 ms: PASS
1 poly (jittered start positions): n=2000 avg=0.036ms worst=0.065ms
6 polys (one 6-token party): n=500 avg=0.208ms worst=0.296ms
1 poly + cellsTouched (scanline): n=2000 avg=0.048ms worst=0.120ms
6 polys + cellsTouched (scanline): n=300 avg=0.268ms worst=0.343ms
1 poly + cellsTouchedOld (prototype reference): n=500 avg=0.720ms worst=1.428ms
TARGET polygon+cells, prototype scene (prototype baseline 0.451): 0.048 ms vs <= 0.451 ms: PASS
== 5k sparse: genScene(world=16384., n=5000, seed=1), avg walls in vision bbox 15.6 ==
1 poly, 5k sparse: n=2000 avg=0.082ms worst=0.127ms
1 poly + cellsTouched, 5k sparse: n=2000 avg=0.096ms worst=0.145ms
1 move check (pathClear, cap-length step), 5k sparse: n=20000 avg=0.010ms worst=0.131ms
TARGET polygon, 5k-wall scene: 0.082 ms vs <= 1.0 ms: PASS
1 poly, 5k sparse: n=2000 avg=0.084ms worst=0.543ms
1 poly + cellsTouched, 5k sparse: n=2000 avg=0.096ms worst=0.567ms
1 move check (pathClear, cap-length step), 5k sparse: n=20000 avg=0.010ms worst=0.134ms
TARGET polygon, 5k-wall scene: 0.084 ms vs <= 1.0 ms: PASS
== 5k dense: genScene(world=4096., n=5000, seed=1), avg walls in vision bbox 206.9 ==
1 poly, 5k dense: n=2000 avg=1.282ms worst=3.079ms
1 poly + cellsTouched, 5k dense: n=2000 avg=1.319ms worst=2.817ms
1 move check (pathClear, cap-length step), 5k dense: n=20000 avg=0.009ms worst=0.116ms
1 poly, 5k dense: n=2000 avg=1.284ms worst=3.178ms
1 poly + cellsTouched, 5k dense: n=2000 avg=1.328ms worst=3.148ms
1 move check (pathClear, cap-length step), 5k dense: n=20000 avg=0.009ms worst=0.055ms
(sink 6023672)
+333 -64
View File
@@ -63,14 +63,20 @@
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -121,7 +127,7 @@ control: exit=0 expected_failed=0 ok
[FAILED] prototype scene, all tokens, doors closed and opened
[FAILED] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tgeometry'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tgeometry'
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
@@ -153,14 +159,20 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tge
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -213,7 +225,7 @@ a: exit=1 expected_failed=1 ok
[FAILED] prototype scene, all tokens, doors closed and opened
[OK] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tgeometry'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tgeometry'
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
@@ -245,14 +257,20 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tge
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -306,7 +324,7 @@ b: exit=1 expected_failed=2 ok
[FAILED] prototype scene, all tokens, doors closed and opened
[OK] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tgeometry'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tgeometry'
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
@@ -338,14 +356,20 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tge
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -399,7 +423,7 @@ c: exit=1 expected_failed=2 ok
[OK] prototype scene, all tokens, doors closed and opened
[OK] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tgeometry'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tgeometry'
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
@@ -431,14 +455,20 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tge
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -491,7 +521,7 @@ d1: exit=1 expected_failed=1 ok
[OK] prototype scene, all tokens, doors closed and opened
[OK] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tgeometry'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tgeometry'
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
@@ -523,14 +553,20 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tge
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -581,7 +617,7 @@ d2: exit=1 expected_failed=1 ok
[FAILED] prototype scene, all tokens, doors closed and opened
[FAILED] random wall fields, cell 32 and 25
[FAILED] negative control: the oracle notices a missing and an invented cell
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tgeometry'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tgeometry'
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
@@ -613,14 +649,20 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tge
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
@@ -707,16 +749,22 @@ e: exit=1 expected_failed=4 ok
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[FAILED] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmoverules'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
@@ -731,7 +779,7 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmo
f: exit=1 expected_failed=1 ok
## g: GM moves checked against walls
# diff server/moverules.nim -> mutated copy:
# 108c108
# 114c114
# < if not inBounds(sc, d): return nack(s)
# ---
# > if not inBounds(sc, d) or not pathClear(sc.walls, s, d, sc.tokenRadius): return nack(s)
@@ -799,16 +847,22 @@ f: exit=1 expected_failed=1 ok
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[FAILED] GM placement and GM move onto a wall never set blocked, and the token can escape
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[FAILED] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[FAILED] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[FAILED] GM drops a token inside a wall -> blocked; a door counts only while closed
[FAILED] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmoverules'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
@@ -891,16 +945,22 @@ g: exit=1 expected_failed=1 ok
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmoverules'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
@@ -916,7 +976,7 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmo
h: exit=1 expected_failed=2 ok
## i: no step cap
# diff server/moverules.nim -> mutated copy:
# 113d112
# 119d118
# < if hypot(dd.x, dd.y) > stepCap(sc, sc.tokens[ti]): return nack(s)
[OK] open space is a circle
[OK] wall blocks
@@ -982,22 +1042,28 @@ h: exit=1 expected_failed=2 ok
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed and does not clear
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmoverules'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[FAILED] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
[OK] P4: probing cannot unflag or move a blocked token
[OK] doors beyond the bound: opening or closing them changes no reply
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tprobing'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tprobing'
[OK] exactly n walls, deterministic per seed, seeds differ
[OK] doors are every 10th wall, all closed; walls stay inside the world (+- jitter)
[OK] walls are non-degenerate and axis-ish segments of room-edge length
@@ -1008,7 +1074,7 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tpr
i: exit=1 expected_failed=2 ok
## j: blocked trigger needs the centre on the wall
# diff server/moverules.nim -> mutated copy:
# 120c120
# 100c100
# < proc overlaps(sc: Scene, t: Token, w: Wall): bool = segDist(t.pos, w.a, w.b) < sc.tokenRadius
# ---
# > proc overlaps(sc: Scene, t: Token, w: Wall): bool = segDist(t.pos, w.a, w.b) < 1e-9
@@ -1076,16 +1142,22 @@ i: exit=1 expected_failed=2 ok
[FAILED] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[FAILED] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[FAILED] blocked token: player moves refused, GM move allowed and does not clear
[FAILED] blocked token: player moves refused, GM move allowed
[FAILED] cleared by removing the wall; unrelated removals keep it
[FAILED] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[FAILED] wall update = remove then add
[OK] GM placement and GM move onto a wall never set blocked, and the token can escape
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
[FAILED] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[FAILED] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[FAILED] KEEP: wall update away from one of two overlapping walls keeps blocked
[FAILED] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[FAILED] GM drops a token inside a wall -> blocked; a door counts only while closed
[FAILED] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmoverules'
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
@@ -1096,7 +1168,204 @@ Error: execution of an external program failed: '/tmp/tmp.jVgrCYYy0I/w/tests/tmo
[OK] walls are non-degenerate and axis-ish segments of room-edge length
# test exit=1; expected tests failed: 2
[FAILED] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
j: exit=1 expected_failed=2 ok
## k: removal/open clears blocked unconditionally (no KEEP)
# diff server/moverules.nim -> mutated copy:
# 144c144
# < if overlaps(sc, sc.tokens[i], w): sc.tokens[i].blocked = overlapsAny(sc, sc.tokens[i])
# ---
# > if overlaps(sc, sc.tokens[i], w): sc.tokens[i].blocked = false
[OK] open space is a circle
[OK] wall blocks
[OK] shared endpoint: no leak at the vertex
[OK] shared vertex: both arms required (mutation d1/d2)
[OK] '<' apex: ray through the shared tip must not leak
[OK] every segment endpoint is a polygon vertex (lower and upper end inclusive)
[OK] rays nudged past a corner: area just beyond a wall end is visible
[OK] shared endpoint: closed corner of box has no crack
[OK] collinear walls act as one
[OK] collinear walls with a gap let light through
[OK] T-junction: no leak and correct shadow
[OK] pillar mid-room casts a shadow, sides visible
[OK] closed door blocks, open door passes
[OK] token exactly at wall endpoint
[OK] token at endpoint of free-standing wall sees along it
[OK] long thin corridor
[OK] wall endpoints behind the viewer: fan stays angularly ordered
[OK] radius clips
[OK] square polygon
[OK] tiny polygon inside one cell
[OK] polygon spanning a cell with no vertex in it
[OK] big polygon includes fully covered interior cells
[OK] degenerate input: fewer than 3 vertices
[OK] touching a cell line: inclusive on the max side, not on the bbox minimum side
[OK] concave polygon: a notch cell is not filled
[OK] every token in seed sees itself and is not walled in
[OK] visibilityPolygon and cellsTouched equal the prototype results
[OK] random visibility polygons: identical cell lists
[OK] random simple polygons (star-shaped, concave): identical cell lists
[OK] grid-aligned integer polygons (edges on cell lines): identical cell lists
[OK] prototype scene, all tokens, doors closed and opened
[OK] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
[OK] diagonal squeeze through corner vertex of L
[OK] moving along a collinear wall is blocked
[OK] doors
[OK] zero-length move
[OK] near pillar: circle overlapping blocked, clear ok (ported)
[OK] closed door blocks near, open door passes (ported)
[OK] 64px corridor and doorway passable on the centreline (ported)
[OK] corner clipping: path passes the wall end closer than r though both ends are clear
[OK] parallel pass: r clear, just under r blocked (touching at exactly r is clear)
[OK] diagonal squeeze past an L corner with a gap narrower than 2r is blocked
[OK] leg of the path inside r of a non-start wall blocks even if start and end are clear
[OK] exactly on a wall: can step off perpendicular, either side, to a clear spot
[OK] exactly on a wall: still refused when it would stay overlapped or run along/through
[OK] r = 0: standing on a wall is not an escape case (touch blocks), as the prototype
[OK] overlapping 10 px off: may leave away from the wall, not cross it, not stay overlapped
[OK] escaping one wall does not excuse another
[OK] escape from a closed door; an open door never needed an escape
[OK] overlapping at a wall end: leave past the end without crossing
[OK] owner check: not yours is mkError, no position
[OK] GM-controlled token (no owner): players get mkError
[OK] step cap = scene default without vision, token vision radius with it
[OK] over-cap, blocked-by-wall, blocked-flag and out-of-bounds nacks are identical
[OK] an accepted move applies and echoes the destination
[OK] player move honours walls (capsule) via moveToken
[OK] GM: ignores walls, step cap and blocked; bounds still apply
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[OK] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[FAILED] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[FAILED] KEEP: wall update away from one of two overlapping walls keeps blocked
[OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[OK] GM drops a token inside a wall -> blocked; a door counts only while closed
[OK] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
[OK] P4: probing cannot unflag or move a blocked token
[OK] doors beyond the bound: opening or closing them changes no reply
[OK] exactly n walls, deterministic per seed, seeds differ
[OK] doors are every 10th wall, all closed; walls stay inside the world (+- jitter)
[OK] walls are non-degenerate and axis-ish segments of room-edge length
# test exit=1; expected tests failed: 2
[FAILED] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[FAILED] KEEP: wall update away from one of two overlapping walls keeps blocked
k: exit=1 expected_failed=2 ok
## l: GM moves never set or clear blocked
# diff server/moverules.nim -> mutated copy:
# 122d121
# < if who.role == roleGM: sc.tokens[ti].blocked = overlapsAny(sc, sc.tokens[ti])
[OK] open space is a circle
[OK] wall blocks
[OK] shared endpoint: no leak at the vertex
[OK] shared vertex: both arms required (mutation d1/d2)
[OK] '<' apex: ray through the shared tip must not leak
[OK] every segment endpoint is a polygon vertex (lower and upper end inclusive)
[OK] rays nudged past a corner: area just beyond a wall end is visible
[OK] shared endpoint: closed corner of box has no crack
[OK] collinear walls act as one
[OK] collinear walls with a gap let light through
[OK] T-junction: no leak and correct shadow
[OK] pillar mid-room casts a shadow, sides visible
[OK] closed door blocks, open door passes
[OK] token exactly at wall endpoint
[OK] token at endpoint of free-standing wall sees along it
[OK] long thin corridor
[OK] wall endpoints behind the viewer: fan stays angularly ordered
[OK] radius clips
[OK] square polygon
[OK] tiny polygon inside one cell
[OK] polygon spanning a cell with no vertex in it
[OK] big polygon includes fully covered interior cells
[OK] degenerate input: fewer than 3 vertices
[OK] touching a cell line: inclusive on the max side, not on the bbox minimum side
[OK] concave polygon: a notch cell is not filled
[OK] every token in seed sees itself and is not walled in
[OK] visibilityPolygon and cellsTouched equal the prototype results
[OK] random visibility polygons: identical cell lists
[OK] random simple polygons (star-shaped, concave): identical cell lists
[OK] grid-aligned integer polygons (edges on cell lines): identical cell lists
[OK] prototype scene, all tokens, doors closed and opened
[OK] random wall fields, cell 32 and 25
[OK] negative control: the oracle notices a missing and an invented cell
[OK] crossing blocked, parallel ok
[OK] grazing an endpoint is blocked
[OK] no leak through shared vertex
[OK] diagonal squeeze through corner vertex of L
[OK] moving along a collinear wall is blocked
[OK] doors
[OK] zero-length move
[OK] near pillar: circle overlapping blocked, clear ok (ported)
[OK] closed door blocks near, open door passes (ported)
[OK] 64px corridor and doorway passable on the centreline (ported)
[OK] corner clipping: path passes the wall end closer than r though both ends are clear
[OK] parallel pass: r clear, just under r blocked (touching at exactly r is clear)
[OK] diagonal squeeze past an L corner with a gap narrower than 2r is blocked
[OK] leg of the path inside r of a non-start wall blocks even if start and end are clear
[OK] exactly on a wall: can step off perpendicular, either side, to a clear spot
[OK] exactly on a wall: still refused when it would stay overlapped or run along/through
[OK] r = 0: standing on a wall is not an escape case (touch blocks), as the prototype
[OK] overlapping 10 px off: may leave away from the wall, not cross it, not stay overlapped
[OK] escaping one wall does not excuse another
[OK] escape from a closed door; an open door never needed an escape
[OK] overlapping at a wall end: leave past the end without crossing
[OK] owner check: not yours is mkError, no position
[OK] GM-controlled token (no owner): players get mkError
[OK] step cap = scene default without vision, token vision radius with it
[OK] over-cap, blocked-by-wall, blocked-flag and out-of-bounds nacks are identical
[OK] an accepted move applies and echoes the destination
[OK] player move honours walls (capsule) via moveToken
[OK] GM: ignores walls, step cap and blocked; bounds still apply
[OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
[OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
[OK] open door added or opened never sets; closing a door on a token does
[FAILED] blocked token: player moves refused, GM move allowed
[OK] cleared by removing the wall; unrelated removals keep it
[OK] cleared by opening the door; a second open is a no-op
[OK] cleared by the GM; not re-set by itself
[OK] wall update = remove then add
[FAILED] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
[FAILED] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
[OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
[OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
[OK] KEEP: wall update away from one of two overlapping walls keeps blocked
[FAILED] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[FAILED] GM drops a token inside a wall -> blocked; a door counts only while closed
[FAILED] GM manual clear inside a wall: player escapes sideways, cannot cross
[OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
[OK] no escape hatch: a player cannot walk through any wall of a boxed room
Error: execution of an external program failed: '/tmp/tmp.l2QZ72lVaE/w/tests/tmoverules'
[OK] P1: probes longer than the cap get one fixed nack regardless of the scene
[OK] P2: scenes differing only beyond the bound give identical replies over 3000 probes
[OK] P3 negative control: a wall inside the disc IS visible through replies (the harness can fail)
[OK] P4: probing cannot unflag or move a blocked token
[OK] doors beyond the bound: opening or closing them changes no reply
[OK] exactly n walls, deterministic per seed, seeds differ
[OK] doors are every 10th wall, all closed; walls stay inside the world (+- jitter)
[OK] walls are non-degenerate and axis-ish segments of room-edge length
# test exit=1; expected tests failed: 3
[FAILED] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
[FAILED] GM drops a token inside a wall -> blocked; a door counts only while closed
[FAILED] GM manual clear inside a wall: player escapes sideways, cannot cross
l: exit=1 expected_failed=3 ok
exit=0
+10 -4
View File
@@ -80,14 +80,20 @@
... [OK] wall added within r of the circle (centre not on it) sets blocked; exactly r does not
... [OK] GM-controlled tokens get the flag too; wall bbox does not matter, distance does
... [OK] open door added or opened never sets; closing a door on a token does
... [OK] blocked token: player moves refused, GM move allowed and does not clear
... [OK] blocked token: player moves refused, GM move allowed
... [OK] cleared by removing the wall; unrelated removals keep it
... [OK] cleared by opening the door; a second open is a no-op
... [OK] cleared by the GM; not re-set by itself
... [OK] wall update = remove then add
... [OK] GM placement and GM move onto a wall never set blocked, and the token can escape
... [OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it, opening frees it
... [OK] unconfirmed (b), pinned: opening a door clears blocked although another closed wall still overlaps
... [OK] GM placement and GM move onto a wall: blocked; player escape works only after a GM clear
... [OK] Q14: a door closed 10 px from a token: token blocked, player refused, GM moves it clear, opening frees it
... [OK] doorway: token in an open doorway, door closes -> blocked, door opens -> free
... [OK] KEEP: opening one door / removing one wall while another overlaps -> still blocked; last one frees
... [OK] KEEP: wall update away from one of two overlapping walls keeps blocked
... [OK] GM moves a stuck token clear -> free; to another wall-overlapping spot -> still blocked
... [OK] GM drops a token inside a wall -> blocked; a door counts only while closed
... [OK] GM manual clear inside a wall: player escapes sideways, cannot cross
... [OK] an unrelated wall change elsewhere does not re-block a GM-cleared token
... [Suite] seed scene
... [OK] no escape hatch: a player cannot walk through any wall of a boxed room
Success: Execution finished