Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TransactWriteItems TableName expectation check for difference string references #42

Open
cgstag opened this issue Jul 12, 2021 · 0 comments

Comments

@cgstag
Copy link

cgstag commented Jul 12, 2021

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant