Package com.soebes.itf.jupiter.extension
Class MavenLocator
java.lang.Object
com.soebes.itf.jupiter.extension.MavenLocator
It's the intention to find the
mvn
executable.
The maven.home
is set during the execution of the
test by the user.
The maven.home
has precedence over searching
of Maven via PATH
. This gives the opportunity
to overload the given Maven version in cases where needed.
- Author:
- Karl Heinz Marbaise
- Implementation Note:
- Currently
maven.home
is given to the maven-failsafe-plugin configuration as a system property. The parameterisRunningOnWindows
is used instead of using things likeorg.junit.jupiter.api.condition.OS.WINDOWS.isCurrentOs()
because they contain static initializers etc. which can't be tested.
-
Constructor Summary
ConstructorDescriptionMavenLocator
(FileSystem fileSystem, Optional<String> pathEnvironment, boolean isRunningOnWindows) -
Method Summary
-
Constructor Details
-
MavenLocator
MavenLocator(FileSystem fileSystem, Optional<String> pathEnvironment, boolean isRunningOnWindows) - Parameters:
fileSystem
- TheFileSystem
which is used.pathEnvironment
- The value ofPATH
if it exists otherwiseOptional.empty()
.isRunningOnWindows
-true
when running on Windows, false otherwise.
-
-
Method Details
-
findMvn
-