Class DockerBuildImageMock
java.lang.Object
net.ssehub.easy.instantiation.core.model.defaultInstantiators.AbstractFileInstantiator
net.ssehub.easy.producer.scenario_tests.mocks.DockerBuildImageMock
- All Implemented Interfaces:
net.ssehub.easy.instantiation.core.model.vilTypes.IVilType
public class DockerBuildImageMock
extends net.ssehub.easy.instantiation.core.model.defaultInstantiators.AbstractFileInstantiator
Mocks the instantiator to build Docker images.
- Author:
- Monika Staciwa
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringdockerBuildImage(net.ssehub.easy.instantiation.core.model.artifactModel.Path baseDirectory, net.ssehub.easy.instantiation.core.model.artifactModel.Path dockerFile, String name) Executes a specific Dockerfile and builds an image.static StringChanges the mocked result for the following calls.Methods inherited from class net.ssehub.easy.instantiation.core.model.defaultInstantiators.AbstractFileInstantiator
determineTargetPath, toString
-
Field Details
-
result
-
-
Constructor Details
-
DockerBuildImageMock
public DockerBuildImageMock()
-
-
Method Details
-
dockerBuildImage
public static String dockerBuildImage(net.ssehub.easy.instantiation.core.model.artifactModel.Path baseDirectory, net.ssehub.easy.instantiation.core.model.artifactModel.Path dockerFile, String name) throws net.ssehub.easy.instantiation.core.model.common.VilException Executes a specific Dockerfile and builds an image.- Parameters:
baseDirectory- the base directory for the build contextdockerFile- the docker file for the container to createname- name of the image with following schema (repository:tag)- Returns:
- the container id, may be null/undefined
- Throws:
net.ssehub.easy.instantiation.core.model.common.VilException- in case of artifact / parameter problems
-
setResult
Changes the mocked result for the following calls.- Parameters:
res- the result values- Returns:
- the original value before calling this method
-