listSuiteRuns method

Future<ListSuiteRunsResponse> listSuiteRuns({
  1. int? maxResults,
  2. String? nextToken,
  3. String? suiteDefinitionId,
  4. String? suiteDefinitionVersion,
})

Lists runs of the specified Device Advisor test suite. You can list all runs of the test suite, or the runs of a specific version of the test suite.

Requires permission to access the ListSuiteRuns action.

May throw InternalServerException. May throw ValidationException.

Parameter maxResults : The maximum number of results to return at once.

Parameter nextToken : A token to retrieve the next set of results.

Parameter suiteDefinitionId : Lists the test suite runs of the specified test suite based on suite definition ID.

Parameter suiteDefinitionVersion : Must be passed along with suiteDefinitionId. Lists the test suite runs of the specified test suite based on suite definition version.

Implementation

Future<ListSuiteRunsResponse> listSuiteRuns({
  int? maxResults,
  String? nextToken,
  String? suiteDefinitionId,
  String? suiteDefinitionVersion,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    50,
  );
  final $query = <String, List<String>>{
    if (maxResults != null) 'maxResults': [maxResults.toString()],
    if (nextToken != null) 'nextToken': [nextToken],
    if (suiteDefinitionId != null) 'suiteDefinitionId': [suiteDefinitionId],
    if (suiteDefinitionVersion != null)
      'suiteDefinitionVersion': [suiteDefinitionVersion],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/suiteRuns',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListSuiteRunsResponse.fromJson(response);
}