1
0
Fork 0
Code Issues Pull requests Projects Releases 2 Packages Wiki Activity Actions Pages

Add function-scoped Logic visualization

This commit is contained in:
Andraxion 2026-07-25 21:08:43 -04:00
parent 9fcafc290c
commit 9b4258c852
22 changed files with 1420 additions and 62 deletions

View file

@ -237,6 +237,7 @@ The test verifies the default behavior.
def test_browser_contains_hiding_source_navigation_and_scrollable_inspector(self) -> None:
self.assertIn('id="restore-hidden"', _GRAPH_BROWSER_HTML)
self.assertIn('id="view-web"', _GRAPH_BROWSER_HTML)
self.assertIn('id="view-logic"', _GRAPH_BROWSER_HTML)
self.assertIn('id="open-node-source"', _GRAPH_BROWSER_HTML)
self.assertIn('id="hide-node"', _GRAPH_BROWSER_HTML)
self.assertIn('id="source-dialog"', _GRAPH_BROWSER_HTML)
@ -455,6 +456,7 @@ if (pruned.prunedCount !== 2) fail("pruned node count");
self.assertIn('id="view-nodes"', html)
self.assertIn('id="view-flow"', html)
self.assertIn('id="view-web"', html)
self.assertIn('id="view-logic"', html)
self.assertIn('id="neighborhood-sections"', html)
self.assertIn('id="relationship-key"', html)
self.assertIn('id="relationship-key-list"', html)
@ -595,6 +597,15 @@ if (pruned.prunedCount !== 2) fail("pruned node count");
self.assertEqual("guide.workflow", web["root"])
self.assertEqual(0, web["hops"]["guide.workflow"])
logic_query = urllib.parse.urlencode({"id": "guide.workflow"})
with urllib.request.urlopen(
f"{base}api/logic?{logic_query}", timeout=2
) as response:
logic = json.load(response)
self.assertTrue(logic["logic"])
self.assertFalse(logic["available"])
self.assertEqual("guide.workflow", logic["root"])
wrong_token = f"{first_url.scheme}://{first_url.netloc}/wrong-token/api/overview"
with self.assertRaises(urllib.error.HTTPError) as missing:
urllib.request.urlopen(wrong_token, timeout=2)