Add additional tests to the network interface (#4370)

* Add a network interface invariant validator and characterization tests as a refactor safety net

* Characterize stack, chain, layer move, signature edit, and preview behaviors in tests

* Sweep network interface invariants after every message in editor tests
This commit is contained in:
Keavon Chambers
2026-09-15 14:36:58 +02:00
committed by Dennis Kobert
parent 3aad7ee8ae
commit faa20bd041
4 changed files with 447 additions and 0 deletions
+4
View File
@@ -98,6 +98,10 @@ impl EditorTestUtils {
panic!("Failed to evaluate graph: {e}");
}
// Sweep the network interface's structural invariants so any desync fails at the message that caused it
let violations = self.active_document().network_interface.validate_invariants();
assert!(violations.is_empty(), "Network interface invariant violations:\n{}", violations.join("\n"));
frontend_messages_from_msg
}