Add test scenario blocked-https-requests
[privoxy.git] / tests / cts / README
1 This directory contains tests that leverage curl's test suite (cts).
2
3 For details about curl see: https://curl.se/
4
5 Some temporary hints are below:
6
7 From the parent directory of the directory with the
8 Privoxy sources do:
9
10  git clone https://github.com/curl/curl.git
11
12  cd curl
13  git checkout -b before-cts-regressions 073268a6de3
14
15  # Build curl as described in GIT-INFO. Note that the configure
16  # call needs to explicitly choose a TLS library. For example
17  # by adding "--with-openssl".
18
19  # Install stunnel
20
21  # Test that curl's tests are working without Privoxy
22  make test
23
24 You can then cd back into privoxy/tests/cts and execute the
25 tests by running:
26
27   run-privoxy-tests.sh
28
29 The script takes care of starting Privoxy with a configuration expected
30 by the tests. Note that unlike privoxy-regression-test.pl it currently
31 does not automatically check that Privoxy has been built with all the
32 features required for the tests to work and simply tries to execute
33 all tests.
34
35 The tests are divided into multiple test scenarios.
36
37 Each test scenario has its own subdirectory with a Privoxy
38 configuration file called privoxy.conf and a data directory
39 containing the test files.
40
41 The tests are written using the "curl test suite file format"
42 described at:
43 https://github.com/curl/curl/blob/master/tests/FILEFORMAT.md
44
45 One extension made is that a <proxy-reply> section is supported
46 which will be used when checking the test results instead of using
47 the <reply> section that would be used otherwise.
48
49 This extension is supported by loading a custom perl library
50 (privoxy-runtests.pm) when running runtests.pl. Loading the library
51 is done with runtests-wrapper.sh which also sets a couple of other
52 required options and is normally called through run-privoxy-tests.sh.