Package com.vaadin.flow.testutil
Class FrontendStubs.ToolStubBuilder
java.lang.Object
com.vaadin.flow.testutil.FrontendStubs.ToolStubBuilder
- Enclosing class:
FrontendStubs
Builds a new instance of
FrontendStubs.ToolStubInfo.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a new instance of tool stub info.withCacheDir(String cacheDir) Adds a stub for npm cache directory.withVersion(String version) Adds a stub for tool version.
-
Method Details
-
withVersion
Adds a stub for tool version. The version will be returned if a tool executable is called with '-v' or '--version' argument. If no value is set, the default one is used.- Parameters:
version- a tool version to stub.- Returns:
- a tool stub info builder.
-
withCacheDir
Adds a stub for npm cache directory. The path to cache will be returned if a tool executable is called with 'cache' argument. If no value is set, the default one is used.- Parameters:
cacheDir- a npm cache dir to stub.- Returns:
- a tool stub info builder.
-
build
Builds a new instance of tool stub info.- Returns:
- a new tool stub info instance.
-