Skip to content
Merged
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
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,17 @@ To run the integration tests, execute the following command:
mvn -Pit verify
```

To debug the UI with a visible browser, disable headless mode using either the
`headless` property or the `debug-ui` profile:

```bash
# system property
mvn -Dit.test=ContextMenuViewIT -Dheadless=false verify

# convenient profile
mvn -Pdebug-ui -Dit.test=ContextMenuViewIT verify
```

## How to use it

Add the addon as a test dependency.
Expand Down
17 changes: 16 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -147,10 +147,16 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.2.5</version>
<configuration>
<systemPropertyVariables>
<headless>${headless}</headless>
</systemPropertyVariables>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>3.5.4</version>
<executions>
<execution>
<goals>
Expand All @@ -165,6 +171,9 @@
</includes>
<trimStackTrace>false</trimStackTrace>
<enableAssertions>true</enableAssertions>
<systemPropertyVariables>
<headless>${headless}</headless>
</systemPropertyVariables>
</configuration>
</plugin>
<plugin>
Expand All @@ -190,6 +199,12 @@
</build>

<profiles>
<profile>
<id>debug-ui</id>
<properties>
<headless>false</headless>
</properties>
</profile>
<profile>
<id>release</id>
<build>
Expand Down Expand Up @@ -251,4 +266,4 @@
</build>
</profile>
</profiles>
</project>
</project>
Binary file modified src/main/bundles/dev.bundle
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,13 @@ protected void select(Locator locator, String val) {
}

protected static boolean isHeadless() {
return true;
String propertyValue = System.getProperty("headless");
if (propertyValue == null || propertyValue.isBlank()) {
propertyValue = System.getenv("HEADLESS");
}
if (propertyValue == null || propertyValue.isBlank()) {
return true;
}
return Boolean.parseBoolean(propertyValue);
}
}
}
Loading