diff options
author | Gerald Combs <gerald@wireshark.org> | 2012-03-30 18:19:35 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2012-03-30 18:19:35 +0000 |
commit | 005e724d27a7ad8dbdda44e285f67db5aa316940 (patch) | |
tree | b6a0ff72e11a05be3b20195f359e37b27209e6b9 /test/suite-io.sh | |
parent | 3a20e1061552455f5f3ddc32e0f95e82f3df5def (diff) |
Fix the location of dhcp.pcap.
svn path=/trunk/; revision=41857
Diffstat (limited to 'test/suite-io.sh')
-rwxr-xr-x | test/suite-io.sh | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/test/suite-io.sh b/test/suite-io.sh index 51d4f0135b..65f34d1092 100755 --- a/test/suite-io.sh +++ b/test/suite-io.sh @@ -21,7 +21,7 @@ # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -# +# # common exit status values @@ -32,7 +32,7 @@ EXIT_ERROR=2 # input of file io_step_input_file() { - $DUT -r dhcp.pcap -w ./testout.pcap > ./testout.txt 2>&1 + $DUT -r "${CAPTURE_DIR}dhcp.pcap" -w ./testout.pcap > ./testout.txt 2>&1 RETURNVALUE=$? if [ ! $RETURNVALUE -eq $EXIT_OK ]; then test_step_failed "exit status of $DUT: $RETURNVALUE" @@ -47,7 +47,7 @@ io_step_input_file() { test_step_failed "No output file!" return fi - + # ok, we got a capture file, does it contain exactly 10 packets? $CAPINFOS ./testout.pcap > ./testout.txt grep -Ei 'Number of packets:[[:blank:]]+4' ./testout.txt > /dev/null @@ -63,9 +63,9 @@ io_step_input_file() { fi } -# piping input file to stdout using "-w -" +# piping input file to stdout using "-w -" io_step_output_piping() { - $DUT -r dhcp.pcap -w - > ./testout.pcap 2>./testout.txt + $DUT -r "${CAPTURE_DIR}dhcp.pcap" -w - > ./testout.pcap 2>./testout.txt RETURNVALUE=$? if [ ! $RETURNVALUE -eq $EXIT_OK ]; then test_step_failed "exit status of $DUT: $RETURNVALUE" @@ -78,7 +78,7 @@ io_step_output_piping() { test_step_failed "No output file!" return fi - + # ok, we got a capture file, does it contain exactly 10 packets? $CAPINFOS ./testout.pcap > ./testout2.txt 2>&1 grep -Ei 'Number of packets:[[:blank:]]+4' ./testout2.txt > /dev/null @@ -93,9 +93,9 @@ io_step_output_piping() { fi } -# piping input file to stdout using "-w -" +# piping input file to stdout using "-w -" io_step_input_piping() { - cat -B dhcp.pcap | $DUT -r - -w ./testout.pcap 2>./testout.txt + cat -B "${CAPTURE_DIR}dhcp.pcap" | $DUT -r - -w ./testout.pcap 2>./testout.txt RETURNVALUE=$? if [ ! $RETURNVALUE -eq $EXIT_OK ]; then $TSHARK -D @@ -110,7 +110,7 @@ io_step_input_piping() { test_step_failed "No output file!" return fi - + # ok, we got a capture file, does it contain exactly 10 packets? $CAPINFOS ./testout.pcap > ./testout2.txt 2>&1 grep -Ei 'Number of packets:[[:blank:]]+4' ./testout2.txt > /dev/null @@ -141,7 +141,7 @@ tshark_io_suite() { dumpcap_io_suite() { #DUT="$DUMPCAP -Q" DUT=$DUMPCAP - + test_step_add "Input file" io_step_input_file } |