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

dynamodb test failing #212

Closed
alimoeeny opened this issue Sep 2, 2014 · 2 comments
Closed

dynamodb test failing #212

alimoeeny opened this issue Sep 2, 2014 · 2 comments

Comments

@alimoeeny
Copy link
Contributor

@nabeken your test TestAddWriteRequestItems is failing and it is hard for me to tell what is wrong, can I ask you to please update your test so that it is more clear, like with individual assertions?
https://github.com/crowdmob/goamz/blob/master/dynamodb/query_builder_test.go#L32
I appreciate your time and contribution very much.
Or if you know what is wrong and what broke the test that will be very useful too.

@nabeken
Copy link
Contributor

nabeken commented Sep 2, 2014

@alimoeeny Okay. I'll take a look. Do you have a log that TestAddWriteRequestItems is failing?

@alimoeeny
Copy link
Contributor Author

@nabeken very much appreciate your help. Here is the travis ci log:


----------------------------------------------------------------------
FAIL: query_builder_test.go:32: QueryBuilderSuite.TestAddWriteRequestItems
query_builder_test.go:147:
    c.Check(queryJson, check.DeepEquals, expectedJson)
... obtained *simplejson.Json = &simplejson.Json{data:map[string]interface {}{"RequestItems":map[string]interface {}{"FooData":[]interface {}{map[string]interface {}{"DeleteRequest":map[string]interface {}{"Key":map[string]interface {}{"TestHashKeyDel":map[string]interface {}{"S":"DelKey"}, "TestRangeKeyDel":map[string]interface {}{"N":"7777777"}}}}, map[string]interface {}{"PutRequest":map[string]interface {}{"Item":map[string]interface {}{"testing":map[string]interface {}{"N":"4"}, "testingbatch":map[string]interface {}{"N":"2111"}, "testingstrbatch":map[string]interface {}{"S":"mystr"}}}}, map[string]interface {}{"PutRequest":map[string]interface {}{"Item":map[string]interface {}{"testing":map[string]interface {}{"N":"444"}, "testingbatch":map[string]interface {}{"N":"93748249272"}, "testingstrbatch":map[string]interface {}{"S":"myotherstr"}}}}}, "TestTable":[]interface {}{map[string]interface {}{"PutRequest":map[string]interface {}{"Item":map[string]interface {}{"TestHashKey":map[string]interface {}{"S":"MyKey"}, "TestRangeKey":map[string]interface {}{"N":"0193820384293"}}}}}}}}
... expected *simplejson.Json = &simplejson.Json{data:map[string]interface {}{"RequestItems":map[string]interface {}{"TestTable":[]interface {}{map[string]interface {}{"PutRequest":map[string]interface {}{"Item":map[string]interface {}{"TestRangeKey":map[string]interface {}{"N":"0193820384293"}, "TestHashKey":map[string]interface {}{"S":"MyKey"}}}}}, "FooData":[]interface {}{map[string]interface {}{"PutRequest":map[string]interface {}{"Item":map[string]interface {}{"testingstrbatch":map[string]interface {}{"S":"mystr"}, "testingbatch":map[string]interface {}{"N":"2111"}, "testing":map[string]interface {}{"N":"4"}}}}, map[string]interface {}{"PutRequest":map[string]interface {}{"Item":map[string]interface {}{"testingstrbatch":map[string]interface {}{"S":"myotherstr"}, "testingbatch":map[string]interface {}{"N":"93748249272"}, "testing":map[string]interface {}{"N":"444"}}}}, map[string]interface {}{"DeleteRequest":map[string]interface {}{"Key":map[string]interface {}{"TestRangeKeyDel":map[string]interface {}{"N":"7777777"}, "TestHashKeyDel":map[string]interface {}{"S":"DelKey"}}}}}}}}
OOPS: 14 passed, 12 skipped, 1 FAILED
--- FAIL: Test (0.01 seconds)
FAIL
exit status 1
FAIL    github.com/crowdmob/goamz/dynamodb  0.014s
The command "go test -v ./dynamodb/" exited with 1.

alimoeeny added a commit that referenced this issue Sep 5, 2014
dynamodb: Fix #212 Iterate over sorted keys by action for stable testing
zined pushed a commit to zined/goamz that referenced this issue Mar 23, 2015
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

2 participants