@Test public void createDeploymentValidatorToStandaloneTest() throws DeploymentException { assertThat("The deployment validator is not the expected", createDeploymentValidator(new StandaloneDeployment()), instanceOf(StandaloneDeploymentValidator.class)); }
public static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment) throws DeploymentException { if (deployment instanceof AgentDeployment) { return new AgentDeploymentValidator(deployment); } else if (deployment instanceof StandaloneDeployment) { return new StandaloneDeploymentValidator(deployment); } else if (deployment instanceof CloudHubDeployment) { return new CloudHubDeploymentValidator(deployment); } else if (deployment instanceof ArmDeployment) { return new ArmDeploymentValidator(deployment); } else if (deployment instanceof RuntimeFabricDeployment) { return new RuntimeFabricDeploymentValidator(deployment); } else { throw new DeploymentException("Cannot configuration is not supported"); } }
DeploymentValidatorFactory { public static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment) throws DeploymentException { if (deployment instanceof AgentDeployment) { return new AgentDeploymentValidator(deployment); } else if (deployment instanceof StandaloneDeployment) { return new StandaloneDeploymentValidator(deployment); } else if (deployment instanceof CloudHubDeployment) { return new CloudHubDeploymentValidator(deployment); } else if (deployment instanceof ArmDeployment) { return new ArmDeploymentValidator(deployment); } else if (deployment instanceof RuntimeFabricDeployment) { return new RuntimeFabricDeploymentValidator(deployment); } else { throw new DeploymentException("Cannot configuration is not supported"); } } }
DeploymentValidatorFactory { public static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment) throws DeploymentException { if (deployment instanceof AgentDeployment) { return new AgentDeploymentValidator(deployment); } else if (deployment instanceof StandaloneDeployment) { return new StandaloneDeploymentValidator(deployment); } else if (deployment instanceof CloudHubDeployment) { return new CloudHubDeploymentValidator(deployment); } else if (deployment instanceof ArmDeployment) { return new ArmDeploymentValidator(deployment); } else if (deployment instanceof RuntimeFabricDeployment) { return new RuntimeFabricDeploymentValidator(deployment); } else { throw new DeploymentException("Cannot configuration is not supported"); } }  }
DeploymentValidatorFactory { public static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment) throws DeploymentException { if (deployment instanceof AgentDeployment) { return new AgentDeploymentValidator(deployment); } else if (deployment instanceof StandaloneDeployment) { return new StandaloneDeploymentValidator(deployment); } else if (deployment instanceof CloudHubDeployment) { return new CloudHubDeploymentValidator(deployment); } else if (deployment instanceof ArmDeployment) { return new ArmDeploymentValidator(deployment); } else if (deployment instanceof RuntimeFabricDeployment) { return new RuntimeFabricDeploymentValidator(deployment); } else { throw new DeploymentException("Cannot configuration is not supported"); } }  static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment); }
DeploymentValidatorFactory { public static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment) throws DeploymentException { if (deployment instanceof AgentDeployment) { return new AgentDeploymentValidator(deployment); } else if (deployment instanceof StandaloneDeployment) { return new StandaloneDeploymentValidator(deployment); } else if (deployment instanceof CloudHubDeployment) { return new CloudHubDeploymentValidator(deployment); } else if (deployment instanceof ArmDeployment) { return new ArmDeploymentValidator(deployment); } else if (deployment instanceof RuntimeFabricDeployment) { return new RuntimeFabricDeploymentValidator(deployment); } else { throw new DeploymentException("Cannot configuration is not supported"); } }  static AbstractDeploymentValidator createDeploymentValidator(Deployment deployment);  }