- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
UpdateTestCaseCommand
Updates a test case.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { AppTestClient, UpdateTestCaseCommand } from "@aws-sdk/client-apptest"; // ES Modules import
// const { AppTestClient, UpdateTestCaseCommand } = require("@aws-sdk/client-apptest"); // CommonJS import
const client = new AppTestClient(config);
const input = { // UpdateTestCaseRequest
testCaseId: "STRING_VALUE", // required
description: "STRING_VALUE",
steps: [ // StepList
{ // Step
name: "STRING_VALUE", // required
description: "STRING_VALUE",
action: { // StepAction Union: only one key present
resourceAction: { // ResourceAction Union: only one key present
m2ManagedApplicationAction: { // M2ManagedApplicationAction
resource: "STRING_VALUE", // required
actionType: "Configure" || "Deconfigure", // required
properties: { // M2ManagedActionProperties
forceStop: true || false,
importDataSetLocation: "STRING_VALUE",
},
},
m2NonManagedApplicationAction: { // M2NonManagedApplicationAction
resource: "STRING_VALUE", // required
actionType: "Configure" || "Deconfigure", // required
},
cloudFormationAction: { // CloudFormationAction
resource: "STRING_VALUE", // required
actionType: "Create" || "Delete",
},
},
mainframeAction: { // MainframeAction
resource: "STRING_VALUE", // required
actionType: { // MainframeActionType Union: only one key present
batch: { // Batch
batchJobName: "STRING_VALUE", // required
batchJobParameters: { // BatchJobParameters
"<keys>": "STRING_VALUE",
},
exportDataSetNames: [ // ExportDataSetNames
"STRING_VALUE",
],
},
tn3270: { // TN3270
script: { // Script
scriptLocation: "STRING_VALUE", // required
type: "Selenium", // required
},
exportDataSetNames: [
"STRING_VALUE",
],
},
},
properties: { // MainframeActionProperties
dmsTaskArn: "STRING_VALUE",
},
},
compareAction: { // CompareAction
input: { // Input Union: only one key present
file: { // InputFile
sourceLocation: "STRING_VALUE", // required
targetLocation: "STRING_VALUE", // required
fileMetadata: { // FileMetadata Union: only one key present
dataSets: [ // DataSetList
{ // DataSet
type: "PS", // required
name: "STRING_VALUE", // required
ccsid: "STRING_VALUE", // required
format: "FIXED" || "VARIABLE" || "LINE_SEQUENTIAL", // required
length: Number("int"), // required
},
],
databaseCDC: { // DatabaseCDC
sourceMetadata: { // SourceDatabaseMetadata
type: "z/OS-DB2", // required
captureTool: "Precisely" || "AWS DMS", // required
},
targetMetadata: { // TargetDatabaseMetadata
type: "PostgreSQL", // required
captureTool: "Precisely" || "AWS DMS", // required
},
},
},
},
},
output: { // Output Union: only one key present
file: { // OutputFile
fileLocation: "STRING_VALUE",
},
},
},
},
},
],
};
const command = new UpdateTestCaseCommand(input);
const response = await client.send(command);
// { // UpdateTestCaseResponse
// testCaseId: "STRING_VALUE", // required
// testCaseVersion: Number("int"), // required
// };
UpdateTestCaseCommand Input
See UpdateTestCaseCommandInput for more details
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
testCaseId Required | string | undefined | The test case ID of the test case. |
description | string | undefined | The description of the test case. |
steps | Step[] | undefined | The steps of the test case. |
UpdateTestCaseCommand Output
See UpdateTestCaseCommandOutput for details
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
testCaseId Required | string | undefined | The test case ID of the test case. |
testCaseVersion Required | number | undefined | The test case version of the test case. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
AccessDeniedException | client | The account or role doesn't have the right permissions to make the request. |
ConflictException | client | The parameters provided in the request conflict with existing resources. |
InternalServerException | server | An unexpected error occurred during the processing of the request. |
ResourceNotFoundException | client | The specified resource was not found. |
ThrottlingException | client | The number of requests made exceeds the limit. |
ValidationException | client | One or more parameter provided in the request is not valid. |
AppTestServiceException | Base exception class for all service exceptions from AppTest service. |