Thanks for the fast reply. Adding Thread.sleep(2000) makes it work. Also, I use a presentation model design and noticed I get a different error when I access the list via the model:
org.loadui.testfx.exceptions.NoNodesFoundException: No nodes matched 'Node should have label "test item"'. Screenshot saved as C:\Projects\fx-testing\screenshot1410566515369.png.
at org.loadui.testfx.GuiTest.assertNodesFound(GuiTest.java:244)
at org.loadui.testfx.GuiTest.find(GuiTest.java:465)
My model has:
private ListProperty<String> leftList = new SimpleListProperty<>(FXCollections.observableArrayList());
public ListProperty<String> leftListProperty() {return leftList;}
... which is bound in the controller:
model.leftListProperty().bindBidirectional(leftListView.itemsProperty());
I'm confused as to why accessing the list via the model makes any difference:
controller.getModel().getLeftList().add("test item");
Ryan