diff options
author | Guy Harris <guy@alum.mit.edu> | 2018-08-10 13:56:15 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2018-08-10 13:56:15 -0700 |
commit | c6ca8a71712729501550714205ab9649b42422aa (patch) | |
tree | a5610c0d3f555b656859ab2503b38ef428044a5c /CONTRIBUTING | |
parent | e76125515c742d80af1819f023d8d20ccf83cb87 (diff) | |
download | tcpdump-c6ca8a71712729501550714205ab9649b42422aa.tar.gz |
Update.
-# is used to indicate which packets differ in how they're dissected,
not to ensure the reproducibility of the output.
We also set TZ to GMT0 to do all time-stamp printing in UTC.
Diffstat (limited to 'CONTRIBUTING')
-rw-r--r-- | CONTRIBUTING | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/CONTRIBUTING b/CONTRIBUTING index 0a5bbd4a..a5875d96 100644 --- a/CONTRIBUTING +++ b/CONTRIBUTING @@ -73,9 +73,13 @@ How to add new code and to update existing code 6) Add/update sample.pcap files We use tests directory to do regression tests on the dissection of captured packets. Those captured packets were saved running tcpdump with option "-w - sample.pcap". Additional options like "-#" and "-n" are used to create - relevant and reproducible output. The actual test compares the current text - output with the expected result (sample.out) saved from a previous version. + sample.pcap". Additional options, such as "-n", are used to create relevant + and reproducible output; "-#" is used to indicate which particular packets + have output that differs. The tests are run with the TZ environment + variable set to GMT0, so that UTC, rather than the local time where the + tests are being run, is used when "local time" values are printed. The + actual test compares the current text output with the expected result + (sample.out) saved from a previous version. Any new/updated fields in a dissector must be present in a sample.pcap file and the corresponding output file. @@ -85,7 +89,7 @@ How to add new code and to update existing code test-name sample.pcap sample.out tcpdump-options The sample.out file can be build by: - (cd tests && ../tcpdump -# -n -r sample.pcap tcpdump-options > sample.out) + (cd tests && TZ=GMT0 ../tcpdump -# -n -r sample.pcap tcpdump-options > sample.out) Or, for convenience, use "./update-test.sh test-name" |