README.tests 1.45 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12
                       README.tests

   Instructions for standalone test regressions of libxml2

libxml2-tests-$version.tar.gz contains 3 standalone C programs as well
as a large amount of tests and results coming from libxml2 itself and
from W3C, NIST, Sun Microsystems, Microsoft and James Clark. Each C
program has a different testing purpose:

  runtest.c : runs libxml2 basic internal regression tests
  runsuite.c: runs libxml2 against external regression tests
  testapi.c : exercises the library public entry points
13
  testchar.c: exercise the check of character ranges and UTF-8 validation
14 15 16

The command:

Daniel Veillard's avatar
Daniel Veillard committed
17 18
  make check
or
19
  make -f Makefile.tests check
20 21

should be sufficient on an Unix system to build and exercise the tests
22
for the version of the library installed on the system. Note however
23
that there isn't backward compatibility provided so if the installed
Daniel Veillard's avatar
Daniel Veillard committed
24
version is older than the testsuite one, failing to compile or run the tests
25 26
is likely. In any event this won't work with an installed libxml2 older
than 2.6.20.
Daniel Veillard's avatar
Daniel Veillard committed
27

Daniel Mustieles's avatar
Daniel Mustieles committed
28
Building on other platforms should be a matter of compiling the C files
29 30 31
like any other program using libxml2, running the test should be done
simply by launching the resulting executables.

Daniel Veillard's avatar
Daniel Veillard committed
32 33 34 35 36
Also note the availability of a "make valgrind" target which will run the
above tests under valgrind to check for memory errors (but this relies
on the availability of the valgrind command and take far more time to
complete).

37
Daniel Veillard
Daniel Veillard's avatar
Daniel Veillard committed
38 39
Mon May  7 2012