@Test(expected = IllegalArgumentException.class) public void deploymentTemplateHandlerWithoutControllerTest() { ContainerHandler containerHandler = getContainerHandler(); PodTemplateHandler podTemplateHandler = new PodTemplateHandler(containerHandler); DeploymentHandler deploymentHandler = new DeploymentHandler(podTemplateHandler); ResourceConfig config = new ResourceConfig.Builder() .imagePullPolicy("IfNotPresent") .withServiceAccount("test-account") .withReplicas(5) .volumes(volumes1) .build(); deploymentHandler.getDeployment(config, images); }
public Deployment getDeployment(ResourceConfig config, List<ImageConfiguration> images) { Deployment deployment = new DeploymentBuilder() .withMetadata(createDeploymentMetaData(config)) .withSpec(createDeploymentSpec(config, images)) .build(); return deployment; }
DeploymentHandler { public Deployment getDeployment(ResourceConfig config, List<ImageConfiguration> images) { Deployment deployment = new DeploymentBuilder() .withMetadata(createDeploymentMetaData(config)) .withSpec(createDeploymentSpec(config, images)) .build(); return deployment; } }
DeploymentHandler { public Deployment getDeployment(ResourceConfig config, List<ImageConfiguration> images) { Deployment deployment = new DeploymentBuilder() .withMetadata(createDeploymentMetaData(config)) .withSpec(createDeploymentSpec(config, images)) .build(); return deployment; } DeploymentHandler(PodTemplateHandler podTemplateHandler); }
DeploymentHandler { public Deployment getDeployment(ResourceConfig config, List<ImageConfiguration> images) { Deployment deployment = new DeploymentBuilder() .withMetadata(createDeploymentMetaData(config)) .withSpec(createDeploymentSpec(config, images)) .build(); return deployment; } DeploymentHandler(PodTemplateHandler podTemplateHandler); Deployment getDeployment(ResourceConfig config,
                                    List<ImageConfiguration> images); }
DeploymentHandler { public Deployment getDeployment(ResourceConfig config, List<ImageConfiguration> images) { Deployment deployment = new DeploymentBuilder() .withMetadata(createDeploymentMetaData(config)) .withSpec(createDeploymentSpec(config, images)) .build(); return deployment; } DeploymentHandler(PodTemplateHandler podTemplateHandler); Deployment getDeployment(ResourceConfig config,
                                    List<ImageConfiguration> images);  }