mirror_iproute2/testsuite/tests/ip/link/new_link.t
Vadim Kochan 30383b074d tests: Add output testing
Added possibility to check command output by grep from the testing
script.

Now TMP_OUT & TMP_ERR are passed from Makefile and changed to
STD_ERR & STD_OUT.

Also changed some existing tests to make output testing.

Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
2015-06-24 23:37:26 -04:00

16 lines
346 B
Bash
Executable File

#!/bin/sh
source lib/generic.sh
ts_log "[Testing add/del virtual links]"
NEW_DEV="$(rand_dev)"
ts_ip "$0" "Add $NEW_DEV dummy interface" link add dev $NEW_DEV type dummy
ts_ip "$0" "Show $NEW_DEV dummy interface" link show dev $NEW_DEV
test_on "$NEW_DEV"
test_lines_count 2
ts_ip "$0" "Del $NEW_DEV dummy interface" link del dev $NEW_DEV