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

Add protocol tests for sparse list primitives #2333

Merged
merged 1 commit into from
Jun 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 14 additions & 2 deletions smithy-aws-protocol-tests/model/restJson1/json-lists.smithy
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ use aws.protocoltests.shared#IntegerEnumList
use aws.protocoltests.shared#GreetingList
use aws.protocoltests.shared#IntegerList
use aws.protocoltests.shared#NestedStringList
use aws.protocoltests.shared#SparseShortList
use aws.protocoltests.shared#StringList
use aws.protocoltests.shared#SparseStringList
use aws.protocoltests.shared#StringSet
Expand Down Expand Up @@ -334,12 +335,17 @@ structure StructureListMember {
"sparseStringList": [
null,
"hi"
],
"sparseShortList": [
null,
2
]
}"""
bodyMediaType: "application/json"
headers: {"Content-Type": "application/json"}
params: {
sparseStringList: [null, "hi"]
sparseStringList: [null, "hi"],
sparseShortList: [null, 2]
}
}
])
Expand All @@ -354,12 +360,17 @@ structure StructureListMember {
"sparseStringList": [
null,
"hi"
],
"sparseShortList": [
null,
2
]
}"""
bodyMediaType: "application/json"
headers: {"Content-Type": "application/json"}
params: {
sparseStringList: [null, "hi"]
sparseStringList: [null, "hi"],
sparseShortList: [null, 2]
}
}
])
Expand All @@ -372,4 +383,5 @@ operation SparseJsonLists {

structure SparseJsonListsInputOutput {
sparseStringList: SparseStringList
sparseShortList: SparseShortList
}
5 changes: 5 additions & 0 deletions smithy-aws-protocol-tests/model/shared-types.smithy
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,11 @@ list ShortList {
member: Short,
}

@sparse
list SparseShortList {
member: Short
}

list IntegerList {
member: Integer,
}
Expand Down
Loading