Tests: Add a test for valid filters
authorChristian Babeux <christian.babeux@efficios.com>
Tue, 16 Oct 2012 18:33:22 +0000 (14:33 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Fri, 19 Oct 2012 19:20:17 +0000 (15:20 -0400)
commit9fec62f705e2143ae8ac72cf0ab1c36245aceda7
tree04a38c4b984a4c11108bcce5bead9b82ee434ef7
parentd8865498212833e7b4d6d67b81426a4ddc04bafe
Tests: Add a test for valid filters

This test validate that for a given filter the expected trace output is
conform to the expected filter behavior.

This test rely on the babelstats utility. With the help of this script,
we can verify that the expected minimum and maximum values on fields of
interest are within the expected ranges.

For example, given 100 iterations on a tracepoint with the field
'intfield', with values starting from 0 and incrementing on each
iteration, and the filter expression 'intfield < 4', we would expect
that the min-max range lie within [0,3].

Thus, if the babelstat computed range does not match the expected range,
this could potentially indicate failure in the filtering mechanism.

Signed-off-by: Christian Babeux <christian.babeux@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
tests/tools/filtering/Makefile.am
tests/tools/filtering/gen-ust-events.c [new file with mode: 0644]
tests/tools/filtering/tp.c [new file with mode: 0644]
tests/tools/filtering/tp.h [new file with mode: 0644]
tests/tools/filtering/valid-filters [new file with mode: 0755]
This page took 0.025615 seconds and 4 git commands to generate.