Skip to content

Commit ea102b5

Browse files
committed
Test that underscored syntax is converted to hyphens on write
1 parent e5037b5 commit ea102b5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

t/12-case_insensitive_headers.t

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ bar
107107
path = "/b",
108108
headers = {
109109
["uSeR-AgENT"] = "test_user_agent",
110+
x_foo = "bar",
110111
},
111112
}
112113
@@ -119,12 +120,14 @@ bar
119120
location = /b {
120121
content_by_lua '
121122
ngx.say(ngx.req.get_headers()["User-Agent"])
123+
ngx.say(ngx.req.get_headers()["X-Foo"])
122124
';
123125
}
124126
--- request
125127
GET /a
126128
--- response_body
127129
test_user_agent
130+
bar
128131
--- no_error_log
129132
[error]
130133
[warn]

0 commit comments

Comments
 (0)