Skip to content

Commit

Permalink
Fix dynamodbattritube broken tests
Browse files Browse the repository at this point in the history
  • Loading branch information
skmcgrail committed May 13, 2020
1 parent 1415c1e commit 6a0272a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
12 changes: 8 additions & 4 deletions service/dynamodb/dynamodbattribute/empty_collections_test.go
Expand Up @@ -6,6 +6,7 @@ import (

"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/service/dynamodb"
"github.com/davecgh/go-spew/spew"
)

type testEmptyCollectionsNumericalScalars struct {
Expand Down Expand Up @@ -616,10 +617,8 @@ var sharedEmptyCollectionsTestCases = []struct {
},
actual: &struct {
Value []byte `dynamodbav:",omitempty"`
}{
Value: []byte{},
},
expected: &struct {
}{},
expected: struct {
Value []byte `dynamodbav:",omitempty"`
}{},
},
Expand Down Expand Up @@ -688,6 +687,11 @@ func TestUnmarshalEmptyCollections(t *testing.T) {
d.EnableEmptyCollections = true
})
err := decoder.Decode(c.in, c.actual)
if i == 22 {
spew.Dump(c.in)
spew.Dump(c.actual)
spew.Dump(c.expected)
}
assertConvertTest(t, i, c.actual, c.expected, err, c.err)
}
}
2 changes: 1 addition & 1 deletion service/dynamodb/dynamodbattribute/shared_test.go
Expand Up @@ -372,7 +372,7 @@ var sharedTestCases = []struct {
encoder.NullEmptyByteSlice = false
},
in: &dynamodb.AttributeValue{M: map[string]*dynamodb.AttributeValue{"Value": {BS: [][]byte{{0x0}, {}, {0x2}}}}},
actual: struct {
actual: &struct {
Value [][]byte `dynamodbav:",binaryset"`
}{},
expected: struct {
Expand Down

0 comments on commit 6a0272a

Please sign in to comment.