Merge branch 'master' into bugfix/1874

This commit is contained in:
Bert Blommers 2019-10-09 08:33:53 +01:00
commit 1fb844972f
13 changed files with 1135 additions and 116 deletions

View file

@ -1995,6 +1995,23 @@ def test_condition_expressions():
},
)
with assert_raises(client.exceptions.ConditionalCheckFailedException):
client.delete_item(
TableName = 'test1',
Key = {
'client': {'S': 'client1'},
'app': {'S': 'app1'},
},
ConditionExpression = 'attribute_not_exists(#existing)',
ExpressionAttributeValues = {
':match': {'S': 'match'}
},
ExpressionAttributeNames = {
'#existing': 'existing',
'#match': 'match',
},
)
@mock_dynamodb2
def test_condition_expression__attr_doesnt_exist():