Skip to content

Commit

Permalink
remove spaces to compare strings irrespective of the formatting added…
Browse files Browse the repository at this point in the history
… by the editor
  • Loading branch information
GnsP committed Oct 24, 2024
1 parent 57d31b7 commit c2a0e32
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ public void verifyDefaultJSEditorValue() {
WebElement jsEditorContentElement = jsEditorElement.findElement(
By.cssSelector("div[class*='ace_text-layer']"));
String editorValue = ElementHelper.getElementText(jsEditorContentElement);
Assert.assertEquals(StringUtils.normalizeSpace(editorValue),
StringUtils.normalizeSpace(defaultJsEditorVal));
Assert.assertEquals(defaultJsEditorVal.replaceAll("\\s+", ""),
editorValue.replaceAll("\\s+", ""));
}

@Then("Replace and verify JS editor value and cursor position")
Expand Down

0 comments on commit c2a0e32

Please sign in to comment.