Skip to content

Commit cd92410

Browse files
committed
test(transport): add failing unresolved endpoint contract
1 parent 258023c commit cd92410

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

‎src/test/java/io/github/easy4j/hermes/security/EndpointPolicyContractTest.java‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,11 @@ void testEp001S1() throws Exception {
3939
"http://127.0.0.1:" + (allowedPort + 1)));
4040
}
4141
}
42+
@Test
43+
void testEp002S2() {
44+
EndpointPolicy policy = EndpointPolicy.strictPublic();
45+
assertThrows(IllegalArgumentException.class, () ->
46+
policy.require("https://hermes-endpoint-does-not-exist.invalid"));
47+
}
48+
4249
}

0 commit comments

Comments
 (0)