Package org.azd.test

Class TestApi

java.lang.Object
org.azd.test.TestApi
All Implemented Interfaces:
TestDetails

public class TestApi extends Object implements TestDetails
  • Constructor Details

    • TestApi

      public TestApi(Connection connection)
      Pass the connection object to work with Service hooks Api
      Parameters:
      connection - Connection object
  • Method Details

    • createTestRun

      public TestRun createTestRun(RunCreateModel runCreateModel) throws AzDException
      Create new test run.
      Specified by:
      createTestRun in interface TestDetails
      Returns:
      TestRun Object TestRun
      Throws:
      AzDException - Default Api Exception handler.
    • getTestRunById

      public TestRun getTestRunById(int runId) throws AzDException
      Get a test run by its ID.
      Specified by:
      getTestRunById in interface TestDetails
      Parameters:
      runId - ID of the run to get.
      Returns:
      TestRun Object TestRun
      Throws:
      AzDException - Default Api Exception handler.
    • getTestRuns

      public TestRuns getTestRuns() throws AzDException
      Get a list of test runs.
      Specified by:
      getTestRuns in interface TestDetails
      Returns:
      TestRun Object TestRun
      Throws:
      AzDException - Default Api Exception handler.
    • getTestRuns

      public TestRuns getTestRuns(int top) throws AzDException
      Get a list of test runs.
      Specified by:
      getTestRuns in interface TestDetails
      Parameters:
      top - Number of test runs to return.
      Returns:
      TestRun Object TestRun
      Throws:
      AzDException - Default Api Exception handler.
    • getTestRuns

      public TestRuns getTestRuns(String buildUri) throws AzDException
      Get a list of test runs.
      Specified by:
      getTestRuns in interface TestDetails
      Parameters:
      buildUri - URI of the build that the runs used.
      Returns:
      TestRun Object TestRun
      Throws:
      AzDException - Default Api Exception handler.
    • getTestRuns

      public TestRuns getTestRuns(int skip, int top, boolean automated, String buildUri, boolean includeRunDetails, String owner, int planId, String tmiRunId) throws AzDException
      Get a list of test runs.
      Specified by:
      getTestRuns in interface TestDetails
      Parameters:
      skip - Number of test runs to skip.
      top - Number of test runs to return.
      automated - If true, only returns automated runs.
      buildUri - URI of the build that the runs used.
      includeRunDetails - If true, include all the properties of the runs.
      owner - Team foundation ID of the owner of the runs.
      planId - ID of the test plan that the runs are a part of.
      tmiRunId - None
      Returns:
      TestRun Object TestRun
      Throws:
      AzDException - Default Api Exception handler.
    • getTestRunStatistics

      public TestRunStatistic getTestRunStatistics(int runId) throws AzDException
      Get test run statistics , used when we want to get summary of a run by outcome.
      Specified by:
      getTestRunStatistics in interface TestDetails
      Parameters:
      runId - ID of the run to get.
      Returns:
      TestRunStatistic Object TestRunStatistic
      Throws:
      AzDException - Default Api Exception handler.
    • deleteTestRun

      public Void deleteTestRun(int runId) throws AzDException
      Delete a test run by its ID.
      Specified by:
      deleteTestRun in interface TestDetails
      Parameters:
      runId - ID of the run to delete.
      Throws:
      AzDException - Default Api Exception handler.