Skip to content

Commit dc3b96c

Browse files
committed
Update tests
1 parent 532e6f3 commit dc3b96c

File tree

7 files changed

+101
-42
lines changed

7 files changed

+101
-42
lines changed

test/protocol-tests-core/src/main/resources/software/amazon/awssdk/protocol/suites/cases/smithy-rpcv2-nonquerycompatible-input.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
},
88
"when": {
99
"action": "marshall",
10-
"operation": "QueryIncompatibleOperation"
10+
"operation": "NonQueryCompatibleOperation"
1111
},
1212
"then": {
1313
"serializedAs": {
@@ -24,7 +24,7 @@
2424
"body": {
2525
"encodedEquals": ""
2626
},
27-
"uri": "/service/NonQueryCompatibleRpcV2Protocol/operation/QueryIncompatibleOperation"
27+
"uri": "/service/NonQueryCompatibleRpcV2Protocol/operation/NonQueryCompatibleOperation"
2828
}
2929
}
3030
}

test/protocol-tests/src/main/resources/codegen-resources/rpcv2-nonquerycompatible/endpoint-rule-set.json

Lines changed: 44 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,25 +6,54 @@
66
"required": true,
77
"documentation": "The AWS region used to dispatch the request.",
88
"type": "String"
9+
},
10+
"UseDualStack": {
11+
"builtIn": "AWS::UseDualStack",
12+
"required": true,
13+
"default": false,
14+
"documentation": "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.",
15+
"type": "Boolean"
16+
},
17+
"UseFIPS": {
18+
"builtIn": "AWS::UseFIPS",
19+
"required": true,
20+
"default": false,
21+
"documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.",
22+
"type": "Boolean"
23+
},
24+
"Endpoint": {
25+
"builtIn": "SDK::Endpoint",
26+
"required": false,
27+
"documentation": "Override the endpoint used to send this request",
28+
"type": "String"
929
}
1030
},
1131
"rules": [
1232
{
13-
"conditions": [],
14-
"endpoint": {
15-
"url": "http://localhost/",
16-
"properties": {
17-
"authSchemes": [
18-
{
19-
"name": "sigv4",
20-
"signingRegion": "{Region}",
21-
"signingName": "jsonrpc"
22-
}
23-
]
24-
},
25-
"headers": {}
26-
},
27-
"type": "endpoint"
33+
"conditions": [
34+
],
35+
"type": "tree",
36+
"rules": [
37+
{
38+
"conditions": [],
39+
"endpoint": {
40+
"url": {
41+
"ref": "Endpoint"
42+
},
43+
"properties": {
44+
"authSchemes": [
45+
{
46+
"name": "sigv4",
47+
"signingRegion": "{Region}",
48+
"signingName": "jsonrpc"
49+
}
50+
]
51+
},
52+
"headers": {}
53+
},
54+
"type": "endpoint"
55+
}
56+
]
2857
}
2958
]
3059
}

test/protocol-tests/src/main/resources/codegen-resources/rpcv2-nonquerycompatible/service-2.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,21 @@
55
"auth": [
66
"aws.auth#sigv4"
77
],
8-
"endpointPrefix": "non-query-compatible-rpcv2",
8+
"endpointPrefix": "nonquerycompatiblerpcv2protocol",
99
"protocol": "smithy-rpc-v2-cbor",
1010
"protocols": [
1111
"smithy-rpc-v2-cbor"
1212
],
13-
"serviceFullName": "Non Query Compatible RpcV2 Protocol Service",
13+
"serviceFullName": "NonQueryCompatibleRpcV2Protocol",
1414
"serviceId": "Non Query Compatible RpcV2 Protocol",
1515
"signatureVersion": "v4",
16-
"signingName": "non-query-compatible-rpcv2",
16+
"signingName": "NonQueryCompatibleRpcV2Protocol",
1717
"targetPrefix": "NonQueryCompatibleRpcV2Protocol",
1818
"uid": "non-query-compatible-rpcv2-protocol-2025-06-20"
1919
},
2020
"operations": {
21-
"QueryIncompatibleOperation": {
22-
"name": "QueryIncompatibleOperation",
21+
"NonQueryCompatibleOperation": {
22+
"name": "NonQueryCompatibleOperation",
2323
"http": {
2424
"method": "POST",
2525
"requestUri": "/"
@@ -29,3 +29,4 @@
2929
},
3030
"shapes": {}
3131
}
32+

test/protocol-tests/src/main/resources/codegen-resources/rpcv2-querycompatible/endpoint-rule-set.json

Lines changed: 44 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,25 +6,54 @@
66
"required": true,
77
"documentation": "The AWS region used to dispatch the request.",
88
"type": "String"
9+
},
10+
"UseDualStack": {
11+
"builtIn": "AWS::UseDualStack",
12+
"required": true,
13+
"default": false,
14+
"documentation": "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.",
15+
"type": "Boolean"
16+
},
17+
"UseFIPS": {
18+
"builtIn": "AWS::UseFIPS",
19+
"required": true,
20+
"default": false,
21+
"documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.",
22+
"type": "Boolean"
23+
},
24+
"Endpoint": {
25+
"builtIn": "SDK::Endpoint",
26+
"required": false,
27+
"documentation": "Override the endpoint used to send this request",
28+
"type": "String"
929
}
1030
},
1131
"rules": [
1232
{
13-
"conditions": [],
14-
"endpoint": {
15-
"url": "http://localhost/",
16-
"properties": {
17-
"authSchemes": [
18-
{
19-
"name": "sigv4",
20-
"signingRegion": "{Region}",
21-
"signingName": "jsonrpc"
22-
}
23-
]
24-
},
25-
"headers": {}
26-
},
27-
"type": "endpoint"
33+
"conditions": [
34+
],
35+
"type": "tree",
36+
"rules": [
37+
{
38+
"conditions": [],
39+
"endpoint": {
40+
"url": {
41+
"ref": "Endpoint"
42+
},
43+
"properties": {
44+
"authSchemes": [
45+
{
46+
"name": "sigv4",
47+
"signingRegion": "{Region}",
48+
"signingName": "jsonrpc"
49+
}
50+
]
51+
},
52+
"headers": {}
53+
},
54+
"type": "endpoint"
55+
}
56+
]
2857
}
2958
]
3059
}

test/protocol-tests/src/main/resources/codegen-resources/rpcv2-querycompatible/service-2.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66
"aws.auth#sigv4"
77
],
88
"awsQueryCompatible": {},
9-
"endpointPrefix": "query-compatible-rpcv2",
9+
"endpointPrefix": "querycompatiblerpcv2protocol",
1010
"protocol": "smithy-rpc-v2-cbor",
1111
"protocols": [
1212
"smithy-rpc-v2-cbor"
1313
],
14-
"serviceFullName": "Query Compatible RpcV2 Protocol Service",
14+
"serviceFullName": "QueryCompatibleRpcV2Protocol",
1515
"serviceId": "Query Compatible RpcV2 Protocol",
1616
"signatureVersion": "v4",
17-
"signingName": "query-compatible-rpcv2",
17+
"signingName": "QueryCompatibleRpcV2Protocol",
1818
"targetPrefix": "QueryCompatibleRpcV2Protocol",
1919
"uid": "query-compatible-rpcv2-protocol-2025-06-20"
2020
},

test/protocol-tests/src/test/java/software/amazon/awssdk/protocol/tests/SmithyRpcV2CborNonQueryCompatibleProtocolTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public static List<TestCase> data() throws IOException {
4141

4242
@BeforeClass
4343
public static void setupFixture() {
44-
testRunner = new ProtocolTestRunner("/models/non-query-compatible-rpcv2-2025-06-20-intermediate.json");
44+
testRunner = new ProtocolTestRunner("/models/nonquerycompatiblerpcv2protocol-2025-06-20-intermediate.json");
4545
}
4646

4747
@Test

test/protocol-tests/src/test/java/software/amazon/awssdk/protocol/tests/SmithyRpcV2CborQueryCompatibleProtocolTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public static List<TestCase> data() throws IOException {
4141

4242
@BeforeClass
4343
public static void setupFixture() {
44-
testRunner = new ProtocolTestRunner("/models/query-compatible-rpcv2-2025-06-20-intermediate.json");
44+
testRunner = new ProtocolTestRunner("/models/querycompatiblerpcv2protocol-2025-06-20-intermediate.json");
4545
}
4646

4747
@Test

0 commit comments

Comments
 (0)