This PR improves regex matching options when using ctest
in downstream projects, such as Bitcoin Core.
For instance, a downstream project users can filter their tests like that:
0ctest --tests-regex "secp256k1"
or
0ctest --exclude-regex "secp256k1"
A ctest
log with this PR:
0$ ctest --test-dir build -j 16
1Internal ctest changing into directory: /home/hebasto/git/secp256k1/secp256k1/build
2Test project /home/hebasto/git/secp256k1/secp256k1/build
3 Start 1: secp256k1_noverify_tests
4 Start 2: secp256k1_tests
5 Start 3: secp256k1_exhaustive_tests
6 Start 4: secp256k1_ecdsa_example
7 Start 5: secp256k1_ecdh_example
8 Start 6: secp256k1_schnorr_example
9 Start 7: secp256k1_ellswift_example
10 Start 8: secp256k1_musig_example
111/8 Test [#4](/bitcoin-core-secp256k1/4/): secp256k1_ecdsa_example .......... Passed 0.00 sec
122/8 Test [#5](/bitcoin-core-secp256k1/5/): secp256k1_ecdh_example ........... Passed 0.00 sec
133/8 Test [#6](/bitcoin-core-secp256k1/6/): secp256k1_schnorr_example ........ Passed 0.00 sec
144/8 Test [#7](/bitcoin-core-secp256k1/7/): secp256k1_ellswift_example ....... Passed 0.00 sec
155/8 Test [#8](/bitcoin-core-secp256k1/8/): secp256k1_musig_example .......... Passed 0.00 sec
166/8 Test [#3](/bitcoin-core-secp256k1/3/): secp256k1_exhaustive_tests ....... Passed 6.19 sec
177/8 Test [#1](/bitcoin-core-secp256k1/1/): secp256k1_noverify_tests ......... Passed 38.83 sec
188/8 Test [#2](/bitcoin-core-secp256k1/2/): secp256k1_tests .................. Passed 91.66 sec
19
20100% tests passed, 0 tests failed out of 8
21
22Total Test time (real) = 91.67 sec