Class EnvironmentsControl

java.lang.Object
com.atlassian.bamboo.testutils.backdoor.BackdoorControl<EnvironmentsControl>
com.atlassian.bamboo.testutils.backdoor.deployments.EnvironmentsControl

public class EnvironmentsControl extends BackdoorControl<EnvironmentsControl>
  • Field Details

    • DEFAULT_DEPLOYMENT_WAIT_TIMEOUT

      public static final com.atlassian.pageobjects.elements.query.Poller.WaitTimeout DEFAULT_DEPLOYMENT_WAIT_TIMEOUT
  • Constructor Details

    • EnvironmentsControl

      public EnvironmentsControl(@NotNull @NotNull BambooEnvironmentData environmentData)
  • Method Details

    • addEnvironment

      public EnvironmentsControl addEnvironment(TestDeploymentProjectDetails deploymentProject, Consumer<TestEnvironmentDetails.Builder> builderConsumer)
    • addEnvironment

      public Consumer<TestEnvironmentDetails> addEnvironment(String deploymentProjectId)
      Save environment
    • addEnvironmentVariable

      public EnvironmentsControl addEnvironmentVariable(TestEnvironmentDetails environment, Consumer<TestVariableDetails.Builder> builderConsumer)
    • addEnvironmentVariable

      public Consumer<TestVariableDetails> addEnvironmentVariable(TestEnvironmentDetails environment)
    • getDockerPipelineConfiguration

      public RestDockerPipelineConfiguration getDockerPipelineConfiguration(String environmentId)
    • waitForSuccessfulDeployment

      public EnvironmentsControl waitForSuccessfulDeployment(String environmentId, String versionName)
      Wait until version was deployed on environment
    • waitForFailedDeployment

      public EnvironmentsControl waitForFailedDeployment(String environmentId, String versionName)
      Wait until version was deployed on environment
    • waitForSuccessfulDeploymentWithReason

      public EnvironmentsControl waitForSuccessfulDeploymentWithReason(String environmentId, String versionName, String reasonSummary)
      Wait until version was deployed on environment with reason
    • waitForCompletedDeployment

      public EnvironmentsControl waitForCompletedDeployment(String environmentId, String versionName)
      Wait until version was deployed on environment
    • waitForCompletedDeployment

      public EnvironmentsControl waitForCompletedDeployment(String environmentId, String versionName, com.atlassian.pageobjects.elements.query.Poller.WaitTimeout timeout)
      Wait until version was deployed on environment
    • waitForInProgressDeployment

      public EnvironmentsControl waitForInProgressDeployment(String environmentId, String versionName)
      Wait until version was deployed on environment
    • waitForInProgressDeployment

      public EnvironmentsControl waitForInProgressDeployment(String environmentId, String versionName, com.atlassian.pageobjects.elements.query.Poller.WaitTimeout timeout)
      Wait until version was deployed on environment
    • waitForDeploymentWithResponse

      public io.restassured.path.json.JsonPath waitForDeploymentWithResponse(String environmentId, org.hamcrest.Matcher<io.restassured.path.json.JsonPath> matcher, com.atlassian.pageobjects.elements.query.Poller.WaitTimeout timeout)
      Wait until matching deployment result appears for an environment
    • assertVersionInHistory

      public EnvironmentsControl assertVersionInHistory(String environmentId, String versionName)
      Verify that version was deployed on an environment. Only first page of results is processed.
    • assertVersionSuccessfullyDeployed

      public EnvironmentsControl assertVersionSuccessfullyDeployed(String environmentId, String versionName)
      Verify that version is currently successfully deployed on an environment.
    • assertVersionDeployed

      public EnvironmentsControl assertVersionDeployed(String environmentId, String versionName)
      Verify that version is currently deployed on an environment.
    • assertVersionNotDeployed

      public EnvironmentsControl assertVersionNotDeployed(String environmentId, String versionName)
      Verify that version is not deployed on an environment. Only first page of results is processed
    • assertNeverDeployedOn

      public EnvironmentsControl assertNeverDeployedOn(String environmentId)
      Verify that version is not deployed on an environment. Only first page of results is processed
    • assertDeploymentResults

      public EnvironmentsControl assertDeploymentResults(String environmentId, org.hamcrest.Matcher<? super Iterable<RestDeploymentResult>> deploymentResultMatcher)
      Verify that version is deployed on an environment. Assumption is made that it will be listed on the first page of results.
    • addRequirement

      public EnvironmentsControl addRequirement(long environmentId, String requirementKey)
    • getRequirements

      public List<RestRequirement> getRequirements(Long environmentId)
    • triggerDeployment

      public RestQueuedDeployment triggerDeployment(String environmentId, long versionId)
    • triggerDeploymentAndExpectFailure

      public void triggerDeploymentAndExpectFailure(String environmentId, long versionId, int expectedStatusCode)
    • resourceRoot

      protected javax.ws.rs.client.WebTarget resourceRoot(String url)
      Description copied from class: BackdoorControl
      Creates a WebResource with authentication parameters set for the default user.
      Overrides:
      resourceRoot in class BackdoorControl<EnvironmentsControl>
    • getDeploymentResultList

      public RestDeploymentResultList getDeploymentResultList(String environmentId)