Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 22 additions & 16 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,6 @@


<developers>
<developer>
<name>Prasant Kumar Sutaria</name>
<email>psutaria@perforce.com</email>
<organization>Perfecto Mobile by Perforce</organization>
<organizationUrl>https://www.perfecto.io</organizationUrl>
</developer>

<developer>
<name>Veronika Juhanson</name>
<email>vjuhanson@perforce.com</email>
Expand Down Expand Up @@ -208,6 +201,20 @@
</repository>
</repositories>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-bom</artifactId>
<version>2.25.1</version>
<scope>import</scope>
<type>pom</type>
</dependency>

</dependencies>

</dependencyManagement>

<dependencies>

<dependency>
Expand Down Expand Up @@ -331,16 +338,14 @@
<version>${commons.logging.version}</version>
</dependency>

<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j.version}</version>
</dependency>
<!-- <dependency>-->
<!-- <groupId>org.apache.logging.log4j</groupId>-->
<!-- <artifactId>log4j-core</artifactId>-->
<!-- </dependency>-->

<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j.version}</version>
</dependency>

<!-- https://mvnrepository.com/artifact/io.github.bonigarcia/webdrivermanager-->
Expand Down Expand Up @@ -459,6 +464,7 @@
<artifactId>jakarta.mail</artifactId>
</exclusion>


</exclusions>
</dependency>
<dependency>
Expand Down Expand Up @@ -619,7 +625,7 @@
</exclusion>
</exclusions>
</dependency>

<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-api</artifactId>
Expand Down Expand Up @@ -654,13 +660,13 @@
<artifactId>jackson-annotations</artifactId>
<version>${jackson.version}</version>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>${jackson.version}</version>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,10 +257,10 @@ private void setReportiumJobDetails(Capabilities desiredCapabilities) {
}

if (jobBranch != null) {
((DesiredCapabilities) desiredCapabilities).setCapability("report.jobBranch", jobBranch);
perfectoOptions.put("report.jobBranch", jobBranch);
}
if (tags != null) {
((DesiredCapabilities) desiredCapabilities).setCapability("report.tags", tags);
perfectoOptions.put("report.tags", tags);
}

((DesiredCapabilities) desiredCapabilities).setCapability("perfecto:options",perfectoOptions);
Expand Down
15 changes: 15 additions & 0 deletions src/main/java/com/quantum/utils/DeviceUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,21 @@ public static boolean verifyVisualText(String text) {
String result = isText(text, null);
return Validator.verifyThat(message,result ,Matchers.equalTo("true"));
}

/**
* Utility method Verify Text using Perfecto's Visual testing.
*
* @param text - Text to verify.
*
* @param timeOutInSec - Timeout in seconds.
*
* @return Boolean representing whether the text is available or not.
*/
public static boolean verifyVisualText(String text, int timeOutInSec) {
String message = String.format("Text: '%s' should be present", text);
String result = isText(text, null);
return Validator.verifyThat(message,result ,Matchers.equalTo("true"));
}

/**
* Utility method Assert Text using Perfecto's Visual testing.
Expand Down