GUACAMOLE-1765: Disable tests by default so the build doesn't require firefox.

This commit is contained in:
James Muehlner
2023-04-07 01:12:33 +00:00
parent bf63964337
commit bd12ac9bc6
4 changed files with 33 additions and 26 deletions

View File

@@ -1,5 +1,4 @@
node/
node_modules/
target/
.tmp/
*~

View File

@@ -44,7 +44,13 @@
between karma and firefox. The default location, /tmp, does not work
if firefox is installed via snap.
-->
<firefox.temp.dir>${project.basedir}/.tmp</firefox.temp.dir>
<firefox.temp.dir>${project.build.directory}/tmp</firefox.temp.dir>
<!--
Skip tests unless requested otherwise with -DskipTests=false.
Skipped by default because these tests require firefox to be installed.
-->
<skipTests>true</skipTests>
</properties>
@@ -125,18 +131,29 @@
</executions>
</plugin>
<!-- Skip tests if configured to do so -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0</version>
<configuration>
<skipTests>${skipTests}</skipTests>
</configuration>
</plugin>
<!-- Ensure the firefox temp directory exists -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>3.1.0</version>
<executions>
<execution>
<id>createFirefoxTempdir</id>
<phase>test-compile</phase>
<phase>test</phase>
<configuration>
<tasks>
<target>
<mkdir dir="${firefox.temp.dir}"/>
</tasks>
</target>
</configuration>
<goals>
<goal>run</goal>
@@ -174,7 +191,7 @@
<!-- Install node.js and NPM before running tests -->
<execution>
<id>install node and npm</id>
<phase>test-compile</phase>
<phase>test</phase>
<goals>
<goal>install-node-and-npm</goal>
</goals>
@@ -183,7 +200,7 @@
<!-- Install test dependencies -->
<execution>
<id>npm install</id>
<phase>test-compile</phase>
<phase>test</phase>
<goals>
<goal>npm</goal>
</goals>