Skip to content

Commit

Permalink
feat(testing): update the API
Browse files Browse the repository at this point in the history
#### testing:v1
The following keys were added:
- schemas.TestMatrix.properties.failFast.description
- schemas.TestMatrix.properties.failFast.type

The following keys were changed:
- resources.projects.resources.testMatrices.methods.create.description
- schemas.AndroidRoboTest.description
- schemas.Date.description
- schemas.Date.properties.day.description
- schemas.Date.properties.month.description
- schemas.Date.properties.year.description
- schemas.ManualSharding.properties.testTargetsForShard.description
- schemas.UniformSharding.properties.numShards.description
  • Loading branch information
yoshi-automation authored and sofisl committed Oct 21, 2020
1 parent 69bc8a5 commit b123d88
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 17 deletions.
22 changes: 13 additions & 9 deletions discovery/testing-v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@
]
},
"create": {
"description": "Creates and runs a matrix of tests according to the given specifications. Unsupported environments will be returned in the state UNSUPPORTED. Matrices are limited to at most 200 supported executions. May return any of the following canonical error codes: - PERMISSION_DENIED - if the user is not authorized to write to project - INVALID_ARGUMENT - if the request is malformed or if the matrix expands to more than 200 supported executions",
"description": "Creates and runs a matrix of tests according to the given specifications. Unsupported environments will be returned in the state UNSUPPORTED. A test matrix is limited to use at most 2000 devices in parallel. May return any of the following canonical error codes: - PERMISSION_DENIED - if the user is not authorized to write to project - INVALID_ARGUMENT - if the request is malformed or if the matrix tries to use too many simultaneous devices.",
"flatPath": "v1/projects/{projectId}/testMatrices",
"httpMethod": "POST",
"id": "testing.projects.testMatrices.create",
Expand Down Expand Up @@ -282,7 +282,7 @@
}
}
},
"revision": "20201001",
"revision": "20201019",
"rootUrl": "https://testing.googleapis.com/",
"schemas": {
"Account": {
Expand Down Expand Up @@ -553,7 +553,7 @@
"type": "object"
},
"AndroidRoboTest": {
"description": "A test of an android application that explores the application on a virtual or physical Android Device, finding culprits and crashes as it goes. Next tag: 29",
"description": "A test of an android application that explores the application on a virtual or physical Android Device, finding culprits and crashes as it goes. Next tag: 30",
"id": "AndroidRoboTest",
"properties": {
"appApk": {
Expand Down Expand Up @@ -840,21 +840,21 @@
"type": "object"
},
"Date": {
"description": "Represents a whole or partial calendar date, e.g. a birthday. The time of day and time zone are either specified elsewhere or are not significant. The date is relative to the Proleptic Gregorian Calendar. This can represent: * A full date, with non-zero year, month and day values * A month and day value, with a zero year, e.g. an anniversary * A year on its own, with zero month and day values * A year and month value, with a zero day, e.g. a credit card expiration date Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.",
"description": "Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values * A month and day value, with a zero year, such as an anniversary * A year on its own, with zero month and day values * A year and month value, with a zero day, such as a credit card expiration date Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.",
"id": "Date",
"properties": {
"day": {
"description": "Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a year by itself or a year and month where the day is not significant.",
"description": "Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.",
"format": "int32",
"type": "integer"
},
"month": {
"description": "Month of year. Must be from 1 to 12, or 0 if specifying a year without a month and day.",
"description": "Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.",
"format": "int32",
"type": "integer"
},
"year": {
"description": "Year of date. Must be from 1 to 9999, or 0 if specifying a date without a year.",
"description": "Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.",
"format": "int32",
"type": "integer"
}
Expand Down Expand Up @@ -1381,7 +1381,7 @@
"id": "ManualSharding",
"properties": {
"testTargetsForShard": {
"description": "Required. Group of packages, classes, and/or test methods to be run for each shard. When any physical devices are selected, the number of test_targets_for_shard must be >= 1 and <= 50. When no physical devices are selected, the number must be >= 1 and <= 250.",
"description": "Required. Group of packages, classes, and/or test methods to be run for each shard. When any physical devices are selected, the number of test_targets_for_shard must be >= 1 and <= 50. When no physical devices are selected, the number must be >= 1 and <= 500.",
"items": {
"$ref": "TestTargetsForShard"
},
Expand Down Expand Up @@ -1757,6 +1757,10 @@
"$ref": "EnvironmentMatrix",
"description": "Required. The devices the tests are being executed on."
},
"failFast": {
"description": "If true, only a single attempt at most will be made to run each execution/shard in the matrix. Flaky test attempts are not affected. Normally, 2 or more attempts are made if a potential infrastructure issue is detected. This feature is for latency sensitive workloads. The incidence of execution failures may be significantly greater for fail-fast matrices and support is more limited because of that expectation.",
"type": "boolean"
},
"flakyTestAttempts": {
"description": "The number of times a TestExecution should be re-attempted if one or more of its test cases fail for any reason. The maximum number of reruns allowed is 10. Default is 0, which implies no reruns.",
"format": "int32",
Expand Down Expand Up @@ -2126,7 +2130,7 @@
"id": "UniformSharding",
"properties": {
"numShards": {
"description": "Required. Total number of shards. When any physical devices are selected, the number must be >= 1 and <= 50. When no physical devices are selected, the number must be >= 1 and <= 250.",
"description": "Required. Total number of shards. When any physical devices are selected, the number must be >= 1 and <= 50. When no physical devices are selected, the number must be >= 1 and <= 500.",
"format": "int32",
"type": "integer"
}
Expand Down
23 changes: 15 additions & 8 deletions src/apis/testing/v1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ export namespace testing_v1 {
thumbnailUrl?: string | null;
}
/**
* A test of an android application that explores the application on a virtual or physical Android Device, finding culprits and crashes as it goes. Next tag: 29
* A test of an android application that explores the application on a virtual or physical Android Device, finding culprits and crashes as it goes. Next tag: 30
*/
export interface Schema$AndroidRoboTest {
/**
Expand Down Expand Up @@ -520,19 +520,19 @@ export namespace testing_v1 {
value?: string | null;
}
/**
* Represents a whole or partial calendar date, e.g. a birthday. The time of day and time zone are either specified elsewhere or are not significant. The date is relative to the Proleptic Gregorian Calendar. This can represent: * A full date, with non-zero year, month and day values * A month and day value, with a zero year, e.g. an anniversary * A year on its own, with zero month and day values * A year and month value, with a zero day, e.g. a credit card expiration date Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
* Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values * A month and day value, with a zero year, such as an anniversary * A year on its own, with zero month and day values * A year and month value, with a zero day, such as a credit card expiration date Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
*/
export interface Schema$Date {
/**
* Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a year by itself or a year and month where the day is not significant.
* Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn&#39;t significant.
*/
day?: number | null;
/**
* Month of year. Must be from 1 to 12, or 0 if specifying a year without a month and day.
* Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.
*/
month?: number | null;
/**
* Year of date. Must be from 1 to 9999, or 0 if specifying a date without a year.
* Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.
*/
year?: number | null;
}
Expand Down Expand Up @@ -919,7 +919,7 @@ export namespace testing_v1 {
*/
export interface Schema$ManualSharding {
/**
* Required. Group of packages, classes, and/or test methods to be run for each shard. When any physical devices are selected, the number of test_targets_for_shard must be &gt;= 1 and &lt;= 50. When no physical devices are selected, the number must be &gt;= 1 and &lt;= 250.
* Required. Group of packages, classes, and/or test methods to be run for each shard. When any physical devices are selected, the number of test_targets_for_shard must be &gt;= 1 and &lt;= 50. When no physical devices are selected, the number must be &gt;= 1 and &lt;= 500.
*/
testTargetsForShard?: Schema$TestTargetsForShard[];
}
Expand Down Expand Up @@ -1195,6 +1195,10 @@ export namespace testing_v1 {
* Required. The devices the tests are being executed on.
*/
environmentMatrix?: Schema$EnvironmentMatrix;
/**
* If true, only a single attempt at most will be made to run each execution/shard in the matrix. Flaky test attempts are not affected. Normally, 2 or more attempts are made if a potential infrastructure issue is detected. This feature is for latency sensitive workloads. The incidence of execution failures may be significantly greater for fail-fast matrices and support is more limited because of that expectation.
*/
failFast?: boolean | null;
/**
* The number of times a TestExecution should be re-attempted if one or more of its test cases fail for any reason. The maximum number of reruns allowed is 10. Default is 0, which implies no reruns.
*/
Expand Down Expand Up @@ -1408,7 +1412,7 @@ export namespace testing_v1 {
*/
export interface Schema$UniformSharding {
/**
* Required. Total number of shards. When any physical devices are selected, the number must be &gt;= 1 and &lt;= 50. When no physical devices are selected, the number must be &gt;= 1 and &lt;= 250.
* Required. Total number of shards. When any physical devices are selected, the number must be &gt;= 1 and &lt;= 50. When no physical devices are selected, the number must be &gt;= 1 and &lt;= 500.
*/
numShards?: number | null;
}
Expand Down Expand Up @@ -1741,7 +1745,7 @@ export namespace testing_v1 {

/**
* testing.projects.testMatrices.create
* @desc Creates and runs a matrix of tests according to the given specifications. Unsupported environments will be returned in the state UNSUPPORTED. Matrices are limited to at most 200 supported executions. May return any of the following canonical error codes: - PERMISSION_DENIED - if the user is not authorized to write to project - INVALID_ARGUMENT - if the request is malformed or if the matrix expands to more than 200 supported executions
* @desc Creates and runs a matrix of tests according to the given specifications. Unsupported environments will be returned in the state UNSUPPORTED. A test matrix is limited to use at most 2000 devices in parallel. May return any of the following canonical error codes: - PERMISSION_DENIED - if the user is not authorized to write to project - INVALID_ARGUMENT - if the request is malformed or if the matrix tries to use too many simultaneous devices.
* @example
* // Before running the sample:
* // - Enable the API at:
Expand Down Expand Up @@ -1777,6 +1781,7 @@ export namespace testing_v1 {
* // {
* // "clientInfo": {},
* // "environmentMatrix": {},
* // "failFast": false,
* // "flakyTestAttempts": 0,
* // "invalidMatrixDetails": "my_invalidMatrixDetails",
* // "outcomeSummary": "my_outcomeSummary",
Expand All @@ -1796,6 +1801,7 @@ export namespace testing_v1 {
* // {
* // "clientInfo": {},
* // "environmentMatrix": {},
* // "failFast": false,
* // "flakyTestAttempts": 0,
* // "invalidMatrixDetails": "my_invalidMatrixDetails",
* // "outcomeSummary": "my_outcomeSummary",
Expand Down Expand Up @@ -1945,6 +1951,7 @@ export namespace testing_v1 {
* // {
* // "clientInfo": {},
* // "environmentMatrix": {},
* // "failFast": false,
* // "flakyTestAttempts": 0,
* // "invalidMatrixDetails": "my_invalidMatrixDetails",
* // "outcomeSummary": "my_outcomeSummary",
Expand Down

0 comments on commit b123d88

Please sign in to comment.