changeset 1520:9521130f6f22

Tests: js TODO adjusted.
author Dmitry Volyntsev <xeioex@nginx.com>
date Tue, 15 Oct 2019 19:36:25 +0300
parents 787d904bdfe0
children b6699ffd9ddd
files js.t js_headers.t js_internal_redirect.t js_request_body.t js_return.t js_subrequests.t js_variables.t
diffstat 7 files changed, 1 insertions(+), 38 deletions(-) [+]
line wrap: on
line diff
--- a/js.t
+++ b/js.t
@@ -245,17 +245,11 @@ like(http_get('/arg?foO=12345'), qr/arg=
 like(http_get('/iarg?foo=12345&foo2=bar&nn=22&foo-3=z'), qr/12345barz/,
 	'r.args iteration');
 
-TODO: {
-local $TODO = 'not yet'
-		unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.3.0';
-
 like(http_get('/iarg?foo=123&foo2=&foo3&foo4=456'), qr/123undefined456/,
 	'r.args iteration 2');
 like(http_get('/iarg?foo=123&foo2=&foo3'), qr/123/, 'r.args iteration 3');
 like(http_get('/iarg?foo=123&foo2='), qr/123/, 'r.args iteration 4');
 
-}
-
 like(http_get('/status'), qr/204 No Content/, 'r.status');
 
 like(http_post('/body'), qr/REQ-BODY/, 'request body');
--- a/js_headers.t
+++ b/js_headers.t
@@ -185,11 +185,6 @@ EOF
 
 ###############################################################################
 
-
-TODO: {
-local $TODO = 'not yet'
-		unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.2.8';
-
 like(http_get('/content_length'), qr/Content-Length: 3/,
 	'set Content-Length');
 like(http_get('/content_type'), qr/Content-Type: text\/xml; charset="utf-8"\r/,
@@ -207,6 +202,5 @@ like(http_get('/hdr_out?foo=123&bar=copy
 unlike(http_get('/hdr_out?bar=empty'), qr/Bar:/, 'r.headersOut empty');
 unlike(http_get('/hdr_out?foo='), qr/Foo:/, 'r.headersOut no value');
 unlike(http_get('/hdr_out?foo'), qr/Foo:/, 'r.headersOut no value 2');
-}
 
 ###############################################################################
--- a/js_internal_redirect.t
+++ b/js_internal_redirect.t
@@ -87,14 +87,8 @@ EOF
 
 ###############################################################################
 
-TODO: {
-local $TODO = 'no njs internalRedirect'
-		unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.2.2';
-
 like(http_get('/test'), qr/redirect/s, 'redirect');
 like(http_get('/test?a=A'), qr/redirectA/s, 'redirect with args');
 like(http_get('/test?dest=named'), qr/named/s, 'redirect to named location');
 
-}
-
 ###############################################################################
--- a/js_request_body.t
+++ b/js_request_body.t
@@ -81,15 +81,11 @@ EOF
 
 ###############################################################################
 
-TODO: {
-local $TODO = 'deprecated api'
-		unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.2.2';
 like(http_post('/body'), qr/REQ-BODY/, 'request body');
 like(http_post('/in_file'), qr/request body is in a file/,
 	'request body in file');
 like(http_post_big('/body'), qr/200.*^(1234567890){1024}$/ms,
 		'request body big');
-}
 
 ###############################################################################
 
--- a/js_return.t
+++ b/js_return.t
@@ -77,7 +77,7 @@ like(http_get('/?c=404'), qr/404 Not.*ht
 
 TODO: {
 my ($v) = http_get('/njs') =~ /^([.0-9]+)$/m;
-local $TODO = 'not yet' unless $v ge '0.2.1' or $Config{archname} !~ /aarch64/;
+local $TODO = 'not yet' unless $Config{archname} !~ /aarch64/;
 
 like(http_get('/?c=inv'), qr/ 500 /, 'return invalid');
 
--- a/js_subrequests.t
+++ b/js_subrequests.t
@@ -526,23 +526,14 @@ http_get('/sr_except_failed_to_convert_a
 http_get('/sr_except_failed_to_convert_options_arg');
 http_get('/sr_uri_except');
 
-TODO: {
-local $TODO = 'not yet'
-	unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.2.4';
-
 is(get_json('/sr_js_in_sr_parent'),
 	'{"e":"parent can only be returned for a subrequest"}',
 	'parent in subrequest js_content');
 
-todo_skip 'leaves coredump', 1
-	unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.2.4';
-
 is(get_json('/sr_in_sr_callback'),
 	'{"e":"subrequest can only be created for the primary request"}',
 	'subrequest for non-primary request');
 
-}
-
 $t->stop();
 
 ok(index($t->read_file('error.log'), 'callback is not a function') > 0,
--- a/js_variables.t
+++ b/js_variables.t
@@ -94,14 +94,8 @@ EOF
 
 ###############################################################################
 
-TODO: {
-local $TODO = 'not yet'
-		unless http_get('/njs') =~ /^([.0-9]+)$/m && $1 ge '0.2.8';
-
 like(http_get('/var_set?a=bar'), qr/test_varbar/, 'var set');
 like(http_get('/content_set?a=bar'), qr/bar/, 'content set');
 like(http_get('/not_found_set'), qr/variable not found/, 'not found exception');
 
-}
-
 ###############################################################################