summaryrefslogtreecommitdiffstats
path: root/test/README
blob: bd29b1f98a7d79dc4f1251c809811a9df45843c1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
Overview
--------
Some basic Apache tests using a local instance of Apache that goes into
the work subdirectory.

suite1.tmpl defines the basic configuration for the tests.

This tries to load libmodnss.so from the parent directory so you must do
a 'make' first before trying to run the tests.

Run the tests
-------------
./setup.sh
nosetests -v test.py

Adding tests
------------

1. Create a new Location in suite1.tmpl with a local configuration to test
   against.

2. Add a call to this location in test.py

Here are the things that can be tested for:

expected = HTTP response code or SSLError() exception
protocol = 
cipher = OpenSSL cipher name


3. If you make a change to the mod_nss code you'll need to either copy
   the new module to work/httpd/lib or rm -rf work and re-run setup.sh
   otherwise you'll be testing against old code.
   
When testing with NSSRequire I sometimes found it difficult to figure out
why a request was being rejected. I added a new compile-time define,
VAR_DEBUG. If this is set then whenever a SSL_ variable is looked up the
result is logged. This is way too much for a running server but great for
debugging tests.