[Scons-dev] Tests

Dirk Bächle tshortik at gmx.de
Tue Sep 4 11:29:58 EDT 2012


Hi Russel,

On 04.09.2012 06:54, Russel Winder wrote:

> Dirk's test framework uses a naming convention to distinguish test

> drivers from other python files. This means a set of test drivers can

> use shared modules which are ignored as tests.

>

> The SCons test framework treats every .py file as a test driver. This

> finds the specially named driver files but also treats the common files

> as tests. Since the common files only contain definitions there are no

> failing tests because of this, but it does mean the test count is wrong

> and that there are spurious tests attempted with neither a pass nor a

> fail.

>

> I can't immediately think of a cure for this.


in my intermediate "test framework" project on Bitbucket I supported the
special "sconstest-*.py" syntax for marking tests.
When integrating the support for testing external Tools into the SCons
core, I skipped this naming rule for the benefit of staying fully
compatible with the regression tests so far, and not having to introduce
another filename syntax.

At the moment, meaning latest revision in "default", the test framework
supports the skipping of whole
folders (like, for a supporting Python package) by adding a
"sconstest.skip" file. A list of single files to skip can also be
specified in a file named ".exclude_tests (see
QMTest/test-framework.rst, sect. "Finding Tests").

Does this help already, or do you need a different functionality?

Best regards,

Dirk



More information about the Scons-dev mailing list