Skip to content

Commit

Permalink
Add a /quitquitquit endpoint to the test server to make killing it …
Browse files Browse the repository at this point in the history
…easy
  • Loading branch information
shs96c committed Dec 4, 2023
1 parent 015595d commit 252b462
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,13 @@ public HandlersForTests(String hostname, int port, Path tempPageDir) {
Route.matching(req -> req.getUri().startsWith("/utf8/"))
.to(() -> new Utf8Handler(webSrc, "/utf8/")),
Route.prefix(TEMP_SRC_CONTEXT_PATH).to(Route.combine(generatedPages)),
Route.get("/quitquitquit")
.to(
() ->
req -> {
System.exit(0);
return new HttpResponse();
}),
new CommonWebResources());

delegate = Route.combine(route, Route.prefix("/common").to(route));
Expand Down

0 comments on commit 252b462

Please sign in to comment.