Skip to content

Commit 6f8e39f

Browse files
committed
Test: describe how to test and fix failed test case
1 parent 46d8555 commit 6f8e39f

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
t/servroot

README.md

+5
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ Table of Contents
99
=================
1010

1111
* [Version](#version)
12+
* [Test](#test)
1213
* [Dependencies](#dependencies)
1314
* [Compatibility](#compatibility)
1415
* [Screenshots](#screenshots)
@@ -79,6 +80,10 @@ Table of Contents
7980
## Version
8081
This document describes nginx-module-vts `v0.1.18` released on 22 Jun 2018.
8182

83+
## Test
84+
Run `sudo prove -r t` after you have installed this module. The `sudo` is required because
85+
the test requires Nginx to listen on port 80.
86+
8287
## Dependencies
8388
* [nginx](http://nginx.org)
8489

t/018.limit_traffic_by_set_key.t

+1-4
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
use Test::Nginx::Socket;
44

5-
plan tests => repeat_each() * blocks() * 12;
5+
plan tests => repeat_each() * blocks() * 11 + 2;
66
no_shuffle();
77
run_tests();
88

@@ -184,15 +184,13 @@ __DATA__
184184
'GET /backend/file.txt',
185185
'GET /backend/file.txt',
186186
'GET /backend/file.txt',
187-
'GET /backend/file.txt',
188187
]
189188
--- error_code eval
190189
[
191190
200,
192191
200,
193192
200,
194193
200,
195-
200,
196194
503,
197195
]
198196
--- response_body_like eval
@@ -202,5 +200,4 @@ __DATA__
202200
'OK',
203201
'OK',
204202
'OK',
205-
'OK',
206203
]

0 commit comments

Comments
 (0)