Tests: adapted js buffer tests to renaming vars to rawVariables.
diff --git a/js.t b/js.t index 9eee9fa..9d283ce 100644 --- a/js.t +++ b/js.t
@@ -307,8 +307,8 @@ like(http_get('/type?path=variables.host'), qr/200 OK.*type: string$/s, 'variables type'); -like(http_get('/type?path=vars.host'), qr/200 OK.*type: buffer$/s, - 'vars type'); +like(http_get('/type?path=rawVariables.host'), qr/200 OK.*type: buffer$/s, + 'rawVariables type'); like(http_post('/type?path=requestBody'), qr/200 OK.*type: string$/s, 'requestBody type');
diff --git a/js_buffer.t b/js_buffer.t index afc2d1d..26fad77 100644 --- a/js_buffer.t +++ b/js_buffer.t
@@ -112,12 +112,13 @@ } function binary_var(r) { - var test = r.vars.binary_remote_addr.equals(Buffer.from([127,0,0,1])); + var test = r.rawVariables.binary_remote_addr + .equals(Buffer.from([127,0,0,1])); r.return(200, test); } export default {njs: test_njs, return: test_return, req_body, res_body, - binary_var}; + binary_var}; EOF
diff --git a/stream_js_buffer.t b/stream_js_buffer.t index 7ade41a..8f1de5f 100644 --- a/stream_js_buffer.t +++ b/stream_js_buffer.t
@@ -99,13 +99,14 @@ } function type(s) { - var v = s.vars.remote_addr; + var v = s.rawVariables.remote_addr; var type = Buffer.isBuffer(v) ? 'buffer' : (typeof v); return type; } function binary_var(s) { - var test = s.vars.binary_remote_addr.equals(Buffer.from([127,0,0,1])); + var test = s.rawVariables + .binary_remote_addr.equals(Buffer.from([127,0,0,1])); return test; }