Hi,

with my recent change merged - https://gerrit.fd.io/r/#/c/5018/ - the
following is supported for running the tests you want:

make test TEST=<filter>:

the (almost) old behaviour is still supported:

TEST=bfd - the (almost) original behaviour, prepends test_ and runs
tests from test_bfd.py
TEST=test_bfd - the same as above

(the difference is that the original behaviour was to run test_bfd*.py,
so if there was a test_bfd2.py present, it would be included too, this
is no longer true)

more interesting is filter format of form:

filter=<file>,<class>,<function>

TEST='bfd.*.*' is equivalent to 1st example (TEST=bfd)
TEST='test_bfd.*.*' is equivalent to 2nd example (TEST=test_bfd)

TEST='bfd.BFDAPITestCase.*' selects all tests from test_bfd.py which are part 
of BFDAPITestCase class
TEST='bfd.BFDAPITestCase.test_add_bfd' selects a single test named test_add_bfd 
from test_bfd.py/BFDAPITestCase
TEST='*.*.test_add_bfd' selects all test functions named test_add_bfd from all 
files/classes

there is a simple rule for the <file> part - if it doesn't start with
'test_', then 'test_' is prepended automatically.

The goal is to allow easy re-runs of a single test function to speed up
development.

Thanks,
Klement
_______________________________________________
vpp-dev mailing list
vpp-dev@lists.fd.io
https://lists.fd.io/mailman/listinfo/vpp-dev

Reply via email to