You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var updateSignedItemResult := wClient.UpdateItem(updateInput);
871
-
expect updateSignedItemResult.Failure?, "UpdateItem should have failed for signed item.";
872
-
// This error is of type DynamoDbEncryptionTransformsException
873
-
// but AWS SDK wraps it into its own type for which customers should be unwrapping.
874
-
// In test vectors, we still have to change the error from AWS SDK to dafny so it turns out to be OpaqueWithText.
875
-
expect updateSignedItemResult.error.OpaqueWithText?, "Error should have been of type OpaqueWithText";
876
-
var hasDynamoDbEncryptionTransformsException? := String.HasSubString(updateSignedItemResult.error.objMessage, "Update Expressions forbidden on signed attributes");
877
-
expect hasDynamoDbEncryptionTransformsException?.Some?, "Error might is not be of type DynamoDbEncryptionTransformsException";
868
+
var updateResult := wClient.UpdateItem(updateInput);
869
+
if writeConfig.config.attributeActionsOnEncrypt[attributeToUpdate] == SE.ENCRYPT_AND_SIGN || writeConfig.config.attributeActionsOnEncrypt[attributeToUpdate] == SE.SIGN_ONLY {
870
+
expect updateResult.Failure?, "UpdateItem should have failed for signed item.";
871
+
// This error is of type DynamoDbEncryptionTransformsException
872
+
// but AWS SDK wraps it into its own type for which customers should be unwrapping.
873
+
// In test vectors, we still have to change the error from AWS SDK to dafny so it turns out to be OpaqueWithText.
874
+
expect updateResult.error.OpaqueWithText?, "Error should have been of type OpaqueWithText";
875
+
var hasDynamoDbEncryptionTransformsException? := String.HasSubString(updateResult.error.objMessage, "Update Expressions forbidden on signed attributes");
876
+
expect hasDynamoDbEncryptionTransformsException?.Some?, "Error might is not be of type DynamoDbEncryptionTransformsException";
0 commit comments