}
public void testInference() throws JaxenException {
Frame page1 = assertHasFrame(root, "page1");
Frame page2 = assertHasFrame(root, "page2");
SyncWire wire = (SyncWire) getWireBidirectional(root, page1, page2);
InputTextField field1 = assertHasInputTextField(page1, "field");
InputTextField field2 = assertHasInputTextField(page2, "field");
assertNotSame(field1, field2);
Function cond = assertHasFunction(root, "Always False");
SimpleCondition cw = assertHasSimpleCondition(root, cond, wire);
// [already in model]
// there should be a Function wire from cond to sync
assertEquals(cw.getFunction(), cond);
assertEquals(cw.getConditioned(), wire);
// [inferred]
// field1 and field2 should be connected by SyncWires
SyncWire sw = assertHasSyncWire(root, field1, field2);
// we should have Event 'edit' in source
Event srcEdit = field1.getOnChange();
Operation srcOp = assertHasOperation(field1, "update");
Event targetEdit = field2.getOnChange();