Skip to content

Commit e0b795c

Browse files
author
Sam Pacos
committed
rename method. remove headless option from maven github build
1 parent 4d69b9f commit e0b795c

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

.github/workflows/maven.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
env:
4646
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
4747
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
48-
run: mvn -B org.jacoco:jacoco-maven-plugin:prepare-agent verify org.jacoco:jacoco-maven-plugin:report org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dheadless -DrecordTests -Dtimeout=20
48+
run: mvn -B org.jacoco:jacoco-maven-plugin:prepare-agent verify org.jacoco:jacoco-maven-plugin:report org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -DrecordTests -Dtimeout=20
4949
- name: Attach reports folder from build
5050
if: ${{ failure() }}
5151
continue-on-error: true

src/main/java/com/dougnoel/sentinel/elements/Element.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -956,7 +956,7 @@ public By getBy() {
956956
* Does not loop for the full timeout.
957957
* @return boolean true if the element is found. false otherwise.
958958
*/
959-
public boolean exists(){
959+
public boolean existsAtThisInstant(){
960960
driver().switchTo().defaultContent();
961961
return findElementInCurrentFrame() != null || findElementInIFrame() != null;
962962
}

src/main/java/com/dougnoel/sentinel/elements/ElementFunctions.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public static boolean waitForEitherElementToExist(String elementName, String oth
119119
.ignoring(WebDriverException.class);
120120

121121
try{
122-
wait.until(x -> getElement(elementName).exists() || getElement(otherElementName).exists());
122+
wait.until(x -> getElement(elementName).existsAtThisInstant() || getElement(otherElementName).existsAtThisInstant());
123123
return true;
124124
}
125125
catch(TimeoutException e){

0 commit comments

Comments
 (0)