• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

conform/H03-May-2022-12,0988,867

data/H03-May-2022-178155

micro-perf/H03-May-2022-216151

unit/H03-May-2022-13189

Makefile.amH A D03-May-2022637 3222

READMEH A D26-Nov-20202.7 KiB6451

config.env.inH A D26-Nov-202066 43

run-tests.shH A D26-Nov-20203.2 KiB158120

test-launcher.shH A D26-Nov-2020827 4029

README

1Outline of test categories:
2
3The conform/ tests:
4-------------------
5These tests should be non-interactive unit-tests that verify a single
6feature is behaving as documented. See conform/ADDING_NEW_TESTS for more
7details.
8
9Although it may seem a bit awkward; all the tests are built into a
10single binary because it makes building the tests *much* faster by avoiding
11lots of linking.
12
13Each test has a wrapper script generated though so running the individual tests
14should be convenient enough. Running the wrapper script will also print out for
15convenience how you could run the test under gdb or valgrind like this for
16example:
17
18  NOTE: For debugging purposes, you can run this single test as follows:
19  $ libtool --mode=execute \
20            gdb --eval-command="b test_cogl_depth_test" \
21            --args ./test-conformance -p /conform/cogl/test_cogl_depth_test
22  or:
23  $ env G_SLICE=always-malloc \
24    libtool --mode=execute \
25            valgrind ./test-conformance -p /conform/cogl/test_cogl_depth_test
26
27By default the conformance tests are run offscreen. This makes the tests run
28much faster and they also don't interfere with other work you may want to do by
29constantly stealing focus. CoglOnscreen framebuffers obviously don't get tested
30this way so it's important that the tests also get run onscreen every once in a
31while, especially if changes are being made to CoglFramebuffer related code.
32Onscreen testing can be enabled by setting COGL_TEST_ONSCREEN=1 in your
33environment.
34
35The micro-bench/ tests:
36-----------------------
37These should be focused performance tests, ideally testing a
38single metric. Please never forget that these tests are synthetic and if you
39are using them then you understand what metric is being tested. They probably
40don't reflect any real world application loads and the intention is that you
41use these tests once you have already determined the crux of your problem and
42need focused feedback that your changes are indeed improving matters. There is
43no exit status requirements for these tests, but they should give clear
44feedback as to their performance. If the framerate is the feedback metric, then
45the test should forcibly enable FPS debugging.
46
47The data/ directory:
48--------------------
49This contains optional data (like images) that can be referenced by a test.
50
51
52Misc notes:
53-----------
54• All tests should ideally include a detailed description in the source
55explaining exactly what the test is for, how the test was designed to work,
56and possibly a rationale for the approach taken for testing.
57
58• When running tests under Valgrind, you should follow the instructions
59available here:
60
61        http://live.gnome.org/Valgrind
62
63and also use the suppression file available inside the data/ directory.
64