How to do it in TestFX 4?
<p>I have a question about testFx 4. 
There is a GUI object, where I want to set text into TextField ("#searchField").</p>

<p>It's works in TestFx 3 as follows:</p>

<pre><code>//Load FXML
@Override
protected Parent getRootNode() {
Parent parent = null;

try {
    FXMLLoader loader = new FXMLLoader(); 
    loader.setResources(ResourceBundle.getBundle(ENTITIES_FIELDS_BUNDLE_PATH, Locale.GERMANY));            
    parent = loader.load(this.getClass().getClassLoader().getResource(SHOW_ALL_LAYOUT_PATH).openStream()); 
} catch (IOException ex) {}

return parent;
}

//Set text into Field and check it's there
@Test
public void setBothnamesAndCheckEnabledSearchButton() {
    TextField searchField = find("#searchField");
    searchField.setText("new text");
    verifyThat("#searchField", hasText("new text"));     
}
</code></pre>

<p>So, it works and everything fine.</p>

<p>100% same case in TestFx 4:</p>

<pre><code>@Override
public void start(Stage stage) throws Exception {
    try {
        FXMLLoader loader = new FXMLLoader(); 
        loader.setResources(ResourceBundle.getBundle(ENTITIES_FIELDS_BUNDLE_PATH, Locale.GERMANY));            
        AnchorPane pane  = (AnchorPane)loader.load(this.getClass().getClassLoader().getResource(SHOW_ALL_LAYOUT_PATH).openStream()); 

        Scene scene = new Scene(pane);
        stage.setScene(scene);
    } catch (IOException ex) {}
}

@Test
public void setBothnamesAndCheckEnabledSearchButton() {
    clickOn("#searchField").write("new text");
    verifyThat("#searchField", hasText("new text"));         
}
</code></pre>

<p>I become always "FxRobotException: the query "#searchField" returned no nodes. So he doesn't "see" the same TextField... </p>

<p>What am I doung wrong? I'm sure it's something really stupid I can't see... Can anybody please help me? Thanks!</p>