wireshark/test
Peter Wu 9ca8a9f87c test: do not silently ignore feature detection failures
When ASAN memleak detection is enabled, any memory leak would result in
an exception and subsequently all features are marked as missing.
With the default profile, any Lua plugin or certain configurations could
cause a memory leak. To avoid such interference, set the configuration
path to a dummy location and warn whenever an error happens nonetheless.

Do not call setProgramPath() immediately, there is no "tshark" binary in
the current working directory anymore. Rely on test.py to set the path.

Change-Id: Idccc3d68eb6f6bb64d3a0b32897acecc65e0dfb6
Reviewed-on: https://code.wireshark.org/review/28867
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2018-07-26 23:16:04 +00:00
..
baseline Test: Add fileformats and I/O. 2018-04-27 19:52:04 +00:00
captures tests: add regression tests for Follow TCP Stream 2018-07-06 12:11:09 +00:00
config ssl,http: rename http-over-ssl to http-over-tls 2016-09-04 13:18:54 +00:00
keys Add support for dissecting UDT over DTLS 2017-07-09 18:25:08 +00:00
lua Remove executable file permission from lua test files 2018-07-23 09:31:48 +00:00
suite_dfilter Test: Add UTF-8 filter tests. 2018-05-30 21:16:38 +00:00
README.test Test: Remove the Bash test scripts. 2018-05-02 04:09:26 +00:00
config.py test: do not silently ignore feature detection failures 2018-07-26 23:16:04 +00:00
conftest.py Tests: add minimal pytest support 2018-07-17 09:04:01 +00:00
hosts.custom Continue to remove $Id$ from top of file 2014-03-31 18:48:06 +00:00
hosts.global Continue to remove $Id$ from top of file 2014-03-31 18:48:06 +00:00
hosts.personal Continue to remove $Id$ from top of file 2014-03-31 18:48:06 +00:00
pytest.ini Tests: add minimal pytest support 2018-07-17 09:04:01 +00:00
subprocesstest.py Tests: add minimal pytest support 2018-07-17 09:04:01 +00:00
suite_capture.py Test: Consolidate our environments. 2018-05-22 16:34:03 +00:00
suite_clopts.py Test: Add UTF-8 filter tests. 2018-05-30 21:16:38 +00:00
suite_decryption.py test: require Libgcrypt 1.6 for TDLS test 2018-05-17 15:30:25 +00:00
suite_dissection.py tcp: add support for reassembling out-of-order segments 2018-06-28 06:10:35 +00:00
suite_fileformats.py Test: Add fileformats and I/O. 2018-04-27 19:52:04 +00:00
suite_follow.py tests: add regression tests for Follow TCP Stream 2018-07-06 12:11:09 +00:00
suite_io.py Test: Add fileformats and I/O. 2018-04-27 19:52:04 +00:00
suite_mergecap.py Test: Add text2pcap. 2018-04-30 21:43:30 +00:00
suite_nameres.py test: add test for resolved addresses 2018-05-12 06:29:55 +00:00
suite_sharkd.py Test: Add sharkd tests. 2018-06-21 03:30:30 +00:00
suite_text2pcap.py Test: Fix capinfos output and command paths. 2018-05-01 18:46:13 +00:00
suite_unittests.py Test+CMake: Make our test grouping more fine-grained. 2018-06-18 19:36:26 +00:00
suite_wslua.py Test: Add wslua. 2018-05-02 00:35:20 +00:00
test.py Test+CMake: Make our test grouping more fine-grained. 2018-06-18 19:36:26 +00:00
util_dump_dhcp_pcap.py Test: Add fileformats and I/O. 2018-04-27 19:52:04 +00:00

README.test

Wireshark Tests

The main testing script is `test.py`. It will attempt to test as much as
possible by default, including packet capture. This means that you will
probably either have to supply a capture interface (`--capture-interface
<interface>`) or disable capture tests (`--disable-capture`). You must
also build the test-programs target in order for the unittests suite to
pass.

To run all tests from CMake do the following:
- Pass `-DTEST_EXTRA_ARGS=--disable-capture` or
  `-DTEST_EXTRA_ARGS=--capture-interface=<interface>`
  as needed for your system.
- Build the “test” target or run ctest, e.g. `ctest --force-new-ctest-process -j 4 --verbose`.

To run all tests directly, run `test.py -p
/path/to/wireshark-build/run-directory <capture args>`.

To see a list of all options, run `test.py -h` or `test.py --help`.

To see a list of all tests, run `test.py -l`.

See the “Wireshark Tests” chapter of the Developer's Guide for details.