Hello,
In my code the assignment of tableName is done when constructing the DynamoDB SDK payloads, by using a string value that is passed around the different packages of my application.
I assume most clients would rather use the String value than the pointer, and use aws.String(myTable) when constructing the dynamodb.TransactWriteItemsInput items.
The side-effect of this, is that aws.String() creates a new reference each time, and therefore the equality check fails on go-dynamock, because it compares the references and not the value.
Please find the following PR with my naive approach to fix the problem : #41
Hello,
In my code the assignment of tableName is done when constructing the DynamoDB SDK payloads, by using a string value that is passed around the different packages of my application.
I assume most clients would rather use the String value than the pointer, and use
aws.String(myTable)when constructing thedynamodb.TransactWriteItemsInputitems.The side-effect of this, is that aws.String() creates a new reference each time, and therefore the equality check fails on go-dynamock, because it compares the references and not the value.
Please find the following PR with my naive approach to fix the problem : #41