use of org.fxmisc.richtext.SelectionImpl in project RichTextFX by FXMisc.
the class MultipleCaretSelectionTests method attempting_to_add_selection_associated_with_different_area_fails.
@Test
public void attempting_to_add_selection_associated_with_different_area_fails() {
InlineCssTextArea area2 = new InlineCssTextArea();
Selection<String, String, String> selection = new SelectionImpl<>("test selection", area2);
interact(() -> {
try {
area.addSelection(selection);
fail();
} catch (IllegalArgumentException e) {
// cannot add a selection associated with a different area
}
});
}
Aggregations