File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
powertools-e2e-tests/src/test/java/software/amazon/lambda/powertools Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ void test_invalidInboundSQSEvent() throws IOException {
85
85
// THEN
86
86
// invocation should fail inbound validation and return an error message
87
87
JsonNode validJsonNode = objectMapper .readTree (invocationResult .getResult ());
88
- assertThat (validJsonNode .get ("errorMessage" ).asText ()).contains ("$.price: is missing but it is required " );
88
+ assertThat (validJsonNode .get ("errorMessage" ).asText ()).contains (": required property 'price' not found " );
89
89
}
90
90
91
91
@ Test
@@ -99,6 +99,6 @@ void test_invalidOutboundSQSEvent() throws IOException {
99
99
// THEN
100
100
// invocation should fail outbound validation and return 400
101
101
JsonNode validJsonNode = objectMapper .readTree (invocationResult .getResult ());
102
- assertThat (validJsonNode .get ("errorMessage" ).asText ()).contains ("$. price: must have an exclusive maximum value of 1000" );
102
+ assertThat (validJsonNode .get ("errorMessage" ).asText ()).contains ("/ price: must have an exclusive maximum value of 1000" );
103
103
}
104
104
}
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ void test_invalidInboundApiGWEvent() throws IOException {
86
86
// invocation should fail inbound validation and return 400
87
87
JsonNode validJsonNode = objectMapper .readTree (invocationResult .getResult ());
88
88
assertThat (validJsonNode .get ("statusCode" ).asInt ()).isEqualTo (400 );
89
- assertThat (validJsonNode .get ("body" ).asText ()).contains ("$.price: is missing but it is required " );
89
+ assertThat (validJsonNode .get ("body" ).asText ()).contains (": required property 'price' not found " );
90
90
}
91
91
92
92
@ Test
@@ -102,6 +102,6 @@ void test_invalidOutboundApiGWEvent() throws IOException {
102
102
JsonNode validJsonNode = objectMapper .readTree (invocationResult .getResult ());
103
103
assertThat (validJsonNode .get ("statusCode" ).asInt ()).isEqualTo (400 );
104
104
assertThat (validJsonNode .get ("body" ).asText ())
105
- .contains ("$. price: must have an exclusive maximum value of 1000" );
105
+ .contains ("/ price: must have an exclusive maximum value of 1000" );
106
106
}
107
107
}
You can’t perform that action at this time.
0 commit comments