Skip to content

Commit

Permalink
Properly close metadata file in integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
geoand committed Mar 9, 2023
1 parent a0b71ff commit 4d22c5f
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -433,9 +433,10 @@ static Properties readQuarkusArtifactProperties(ExtensionContext context) {
}
throw new IllegalStateException(errorMessage);
}
try {
Properties properties = new Properties();
properties.load(new FileInputStream(artifactProperties.toFile()));

Properties properties = new Properties();
try (var fis = new FileInputStream(artifactProperties.toFile())) {
properties.load(fis);
return properties;
} catch (IOException e) {
throw new UncheckedIOException(
Expand Down

0 comments on commit 4d22c5f

Please sign in to comment.