In other words, this test fails on Mac but not on Linux:
public class Test extends InlineCssTextAreaAppTest {
private String firstWord = "Some";
private String firstParagraph = firstWord + " text goes here";
private String extraText = "This is extra text";
@Test
public void pressing_mouse_on_selection_and_dragging_and_releasing_moves_selected_text_to_that_position() {
// setup
String twoSpaces = " ";
interact(() -> {
area.replaceText(firstParagraph + "\n" + twoSpaces + extraText);
area.selectRange(0, firstWord.length());
});
String selText = area.getSelectedText();
Bounds letterInFirstWord = area.getCharacterBoundsOnScreen(1, 2).get();
int insertionPosition = firstParagraph.length() + 2;
Bounds insertionBounds = area.getCharacterBoundsOnScreen(insertionPosition, insertionPosition + 1).get();
moveTo(letterInFirstWord)
.press(PRIMARY)
.dropTo(insertionBounds);
String expectedText = firstParagraph.substring(firstWord.length())
+ "\n" + " " + firstWord + " " + extraText;
assertEquals(insertionPosition, area.getCaretPosition());
// Mac build fails here
assertEquals(selText, area.getSelectedText());
assertEquals(expectedText, area.getText());
}
}
In other words, this test fails on Mac but not on Linux: