Test pcap example
This commit is contained in:
parent
24d45bc0ab
commit
5a85dfd7a0
|
@ -28,7 +28,7 @@ pytest:
|
||||||
- pip install -r requirements/dev.txt
|
- pip install -r requirements/dev.txt
|
||||||
- pytest .
|
- pytest .
|
||||||
|
|
||||||
test_package:
|
test_package_and_examples:
|
||||||
stage: test
|
stage: test
|
||||||
script:
|
script:
|
||||||
- pip install -r requirements/dev.txt
|
- pip install -r requirements/dev.txt
|
||||||
|
|
BIN
examples/print_pcap_files/07_dm1.pcap
Normal file
BIN
examples/print_pcap_files/07_dm1.pcap
Normal file
Binary file not shown.
|
@ -71,3 +71,19 @@ cp dist/twnet_parser-*.tar.gz /tmp/twnet_parser_test/
|
||||||
}
|
}
|
||||||
|
|
||||||
echo "[*] venv tests passed."
|
echo "[*] venv tests passed."
|
||||||
|
|
||||||
|
#
|
||||||
|
# examples/print_pcap_files
|
||||||
|
#
|
||||||
|
|
||||||
|
pushd examples/print_pcap_files || exit 1
|
||||||
|
|
||||||
|
pip install dpkt || exit 1
|
||||||
|
./print_pcap_files.py 07_dm1.pcap || exit 1
|
||||||
|
if ! ./print_pcap_files.py 07_dm1.pcap | grep -q snap_empty
|
||||||
|
then
|
||||||
|
echo "Error: examples/print_pcap_files.py did not print snap_empty"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
popd || exit 1
|
||||||
|
|
Loading…
Reference in a new issue