mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-20 03:18:06 +08:00
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:
@@ -77,6 +77,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
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user