Skip to content

Commit

Permalink
qs routing
Browse files Browse the repository at this point in the history
  • Loading branch information
ericminio committed Apr 26, 2024
1 parent f8aa795 commit 0834ea5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions stub-json/about/tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ function test_qs_based_route_one {
assertequals "$body" '{ "one":1 }'
}

function test_qs_based_route_one {
function test_qs_based_route_two {
nginx_reload_configuration
body=$(curl http://localhost:8080/qs?path=2 | json)
body=$(curl "http://localhost:8080/qs?noise=before&path=2&extra=after" | json)


assertequals "$body" '{ "two":2 }'
Expand Down
2 changes: 1 addition & 1 deletion stub-json/nginx/conf.d/default.conf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
map $query_string $matching {
~path=2 'two';
~*path=2 'two';
default 'one';
}

Expand Down

0 comments on commit 0834ea5

Please sign in to comment.