• Home
  • History
  • Annotate
  • only in this directory
NameDateSize

..24-Apr-201411

00basic.tH A D20-Feb-2013431

01pod.tH A D20-Feb-2013140

02pod-coverage.tH A D20-Feb-2013172

05new.tH A D20-Feb-2013851

10init.tH A D20-Feb-2013890

11log.tH A D20-Feb-20131.1 KiB

15accessors.tH A D20-Feb-20132.8 KiB

15deprecated.tH A D20-Feb-20131.7 KiB

16stash.tH A D20-Feb-2013828

17fstack.tH A D20-Feb-20131.6 KiB

18engine.tH A D20-Feb-20132.1 KiB

20dummy.tH A D20-Feb-20132.2 KiB

20keepalive.tH A D20-Feb-20132.7 KiB

22http.tH A D20-Feb-20132 KiB

22transparent.tH A D20-Feb-20132.1 KiB

23connect.tH A D20-Feb-20132.1 KiB

23https.tH A D20-Feb-20132.4 KiB

40push_filters.tH A D20-Feb-20131.9 KiB

41filters.tH A D20-Feb-2013453

42will_modify.tH A D20-Feb-20131.8 KiB

50hopbyhop.tH A D20-Feb-20133.9 KiB

50standard.tH A D20-Feb-20134.5 KiB

50via.tH A D20-Feb-20132.3 KiB

51simple.tH A D20-Feb-2013872

51simple2.tH A D20-Feb-20131.4 KiB

61simple.tH A D20-Feb-20131.8 KiB

61simple2.tH A D20-Feb-20131.9 KiB

64htmltext.tH A D20-Feb-20131.5 KiB

64lines.tH A D20-Feb-20131.8 KiB

64tags.tH A D20-Feb-20131 KiB

66htmlparser.tH A D20-Feb-20131.6 KiB

67complete.tH A D20-Feb-20131.5 KiB

67save.tH A D20-Feb-20136 KiB

71rot13.tH A D20-Feb-20131.4 KiB

90diveintomark.tH A D20-Feb-20132.5 KiB

READMEH A D20-Feb-20133 KiB

test.htmlH A D20-Feb-2013322

Utils.pmH A D20-Feb-20133.3 KiB

README

1README file for the HTTP::Proxy tests
2
3* Helper modules
4
5HTTP::Proxy can test itself without using the network,
6thanks to the HTTP::Daemon module.
7
8But since I want to test the proxy against "real" servers,
9I also need to test it with an internet connection.
10
11localhost tests work as follows:
12 - a HTTP::Daemon is created and forked, that will serve
13   a certain number of simple requests
14 - a HTTP::Proxy is created and forked
15 - a LWP::UserAgent is created and connects to the proxy
16 - each of those process can run its own tests independantly,
17   thanks to Test::More
18
19The t/Utils.pm files (use t::Utils in some test files) exports
20several functions:
21 - server_start()
22   starts a new HTTP::Daemon
23 - server_next( [ \&answer ] )
24   returns the next response from the server (accepts a coderef)
25 - fork_proxy( $proxy, [ \&end ] )
26   fork a proxy server passed as an argument, with an optionnel
27   subroutine to run at the end
28 - web_ok()
29   test if the actual WWW is available for testing
30 - bare_request( $url, $headers, $proxy )
31   send a simple request through the proxy without LWP::UA
32   return a string containing the full response
33
34* Test categories
35
36The tests are prefixed with a number, which indicates several categories:
37
380x - Basic tests
39     t/00basic.t        - use HTTP::Proxy works
40     t/01pod.t          - the POD is correct
41     t/05new.t          - the HTTP::Proxy constructor
42
431x - Minimal functionnality tests
44     t/10init.t         - the proxy initialisation
45     t/11log.t          - the log() and logmask() methods
46     t/15accessors.t    - the proxy accessors
47     t/17fstack.t       - the internal HTTP::Proxy::FilterStack object
48
492x - Network protocols test
50     t/20dummy.t        - tests against a dummy web server
51     t/20keepalive.t    - test the keep-alive connections
52     t/22http.t         - test actual HTTP servers
53     t/22transparent.t  - test transparent proxying
54     t/23connect.t      - test CONNECT to a ssh server
55     t/23https.t        - test CONNECT for SSL
56
573x - (Reserved for future use)
58
594x - Filter-related functions
60     t/40push_filters.t - the push_filter method
61
625x - Internal header filters
63     t/50hopbyhop.t     - check hop-by-hop headers removal
64     t/50standard.t     - check other headers removal
65     t/50via.t          - check the Via: headers
66     t/51simple.t       - HTTP::Proxy::HeaderFilter::simple
67     t/51simple2.t      - HTTP::Proxy::HeaderFilter::simple with a real proxy
68
696x - Internal body filters
70     t/61simple.t       - HTTP::Proxy::BodyFilter::simple
71     t/61simple2.t      - HTTP::Proxy::BodyFilter::simple with a real proxy
72     t/64htmltext.t     - HTTP::Proxy::BodyFilter::htmltext
73     t/64lines.t        - HTTP::Proxy::BodyFilter::lines
74     t/64tags.t         - HTTP::Proxy::BodyFilter::tags
75     t/66htmlparser.t   - HTTP::Proxy::BodyFilter::htmlparser
76
777x - Complex filter chains
78     t/71rot13.t        - a simple ROT13 filter set
79
808x - (Reserved for future use)
81
829x - miscellaneous tests
83     t/90diveintomark.t - test the proxy against a lot of status codes
84
85