-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #16 from Bhashinee/main
Update the test cases to match the recent dynamodb connector changes
- Loading branch information
Showing
2 changed files
with
14 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,8 +36,8 @@ Client dynamoDBStreamClient = check new (config); | |
@test:BeforeSuite | ||
function updateItem() returns error? { | ||
dynamodb:ItemCreateInput request = { | ||
tableName: mainTable, | ||
item: { | ||
TableName: mainTable, | ||
Item: { | ||
"LastPostDateTime": { | ||
"S": "201303190422" | ||
}, | ||
|
@@ -61,11 +61,11 @@ function updateItem() returns error? { | |
"S": "[email protected]" | ||
} | ||
}, | ||
conditionExpression: "ForumName <> :f and Subject <> :s", | ||
returnValues: dynamodb:ALL_OLD, | ||
returnItemCollectionMetrics: dynamodb:SIZE, | ||
returnConsumedCapacity: dynamodb:TOTAL, | ||
expressionAttributeValues: { | ||
ConditionExpression: "ForumName <> :f and Subject <> :s", | ||
ReturnValues: dynamodb:ALL_OLD, | ||
ReturnItemCollectionMetrics: dynamodb:SIZE, | ||
ReturnConsumedCapacity: dynamodb:TOTAL, | ||
ExpressionAttributeValues: { | ||
":f": { | ||
"S": "Amazon DynamoDB" | ||
}, | ||
|
@@ -131,18 +131,18 @@ function testGetRecords() returns error? { | |
@test:AfterSuite | ||
function deleteUpdatedItem() returns error? { | ||
dynamodb:ItemDeleteInput delRequest = { | ||
tableName: mainTable, | ||
'key: { | ||
TableName: mainTable, | ||
Key: { | ||
"ForumName": { | ||
"S": "Amazon DynamoDB" | ||
}, | ||
"Subject": { | ||
"S": "How do I update multiple items?" | ||
} | ||
}, | ||
returnConsumedCapacity: dynamodb:TOTAL, | ||
returnItemCollectionMetrics: dynamodb:SIZE, | ||
returnValues: dynamodb:ALL_OLD | ||
ReturnConsumedCapacity: dynamodb:TOTAL, | ||
ReturnItemCollectionMetrics: dynamodb:SIZE, | ||
ReturnValues: dynamodb:ALL_OLD | ||
}; | ||
_= check dynamodbClient->deleteItem(delRequest); | ||
} |