Skip to content

Commit 91d701d

Browse files
committed
updated tests to reflect the fix in commit ccb0cbe.
1 parent d333a36 commit 91d701d

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

t/038-match-o.t

+7-7
Original file line numberDiff line numberDiff line change
@@ -471,15 +471,15 @@ not matched!
471471
GET /re
472472
--- response_body
473473
1234
474-
4
474+
5
475475

476476

477477

478478
=== TEST 23: match with ctx and a pos
479479
--- config
480480
location /re {
481481
content_by_lua '
482-
local ctx = { pos = 2 }
482+
local ctx = { pos = 3 }
483483
m = ngx.re.match("1234, hello", "([0-9]+)", "o", ctx)
484484
if m then
485485
ngx.say(m[0])
@@ -494,7 +494,7 @@ not matched!
494494
GET /re
495495
--- response_body
496496
34
497-
4
497+
5
498498

499499

500500

@@ -574,7 +574,7 @@ nil
574574
ngx.say(m and m[0])
575575
ngx.say(ctx.pos)
576576
577-
ctx.pos = 0
577+
ctx.pos = 1
578578
m = ngx.re.match("hi, 1234", "([A-Z]+)", "o", ctx)
579579
ngx.say(m and m[0])
580580
ngx.say(ctx.pos)
@@ -584,11 +584,11 @@ nil
584584
GET /re
585585
--- response_body
586586
hello
587-
5
587+
6
588588
okay
589-
10
589+
11
590590
nil
591-
0
591+
1
592592

593593

594594

0 commit comments

Comments
 (0)