Skip to content
This repository has been archived by the owner on Apr 5, 2024. It is now read-only.

Commit

Permalink
Ensure TypeDB processes spawned by tests use the same java installati…
Browse files Browse the repository at this point in the history
…on (#156)

## What is the goal of this PR?
We ensure the TypeDB process spawned by the runner utility uses the same java version as the test. This avoids issues due to the runner using a different java installation from the host machine.

## What are the changes implemented in this PR?
* Sets the `JAVA_HOME` environment variable on the `ProcessExecutor` used by TypeDB (core & enterprise) runners.
  • Loading branch information
krishnangovindraj authored Oct 19, 2023
1 parent 5d78f57 commit 303ccab
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions test/Util.java
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ public static ProcessExecutor createProcessExecutor(Path directory) {
.redirectOutput(System.out)
.redirectError(System.err)
.readOutput(true)
.environment("JAVA_HOME", System.getProperty("java.home"))
.destroyOnExit();
}

Expand Down

0 comments on commit 303ccab

Please sign in to comment.