summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2010-11-17 21:42:13 +0100
committerJim Meyering <meyering@redhat.com>2010-11-17 21:46:22 +0100
commita8c8484ee17f09ac92a27308b6ee5eaf4304bddc (patch)
tree7306997d582e94bd09dd393d5bdb30be9f8624e7 /tests
parent293c37b9061c1afd0acd143bbded637a8f00b3a0 (diff)
downloadcoreutils-a8c8484ee17f09ac92a27308b6ee5eaf4304bddc.tar.xz
tests: convert "... env -- prog --version" uses
E.g., -test "$VERBOSE" = yes && env -- pwd --version +print_ver_ pwd git grep -l 'VERBOSE.*--version'|xargs perl -pi -e \ 's/test "\$VERBOSE" = yes && env -- (\w+) --version/print_ver_ $1/'
Diffstat (limited to 'tests')
-rwxr-xr-xtests/misc/printenv2
-rwxr-xr-xtests/misc/printf2
-rwxr-xr-xtests/misc/printf-hex2
-rwxr-xr-xtests/misc/printf-surprise2
-rwxr-xr-xtests/misc/pwd-long2
-rwxr-xr-xtests/misc/pwd-option2
6 files changed, 6 insertions, 6 deletions
diff --git a/tests/misc/printenv b/tests/misc/printenv
index 67173ed58..4a569173a 100755
--- a/tests/misc/printenv
+++ b/tests/misc/printenv
@@ -17,7 +17,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
. "${srcdir=.}/init.sh"; path_prepend_ ../src
-test "$VERBOSE" = yes && env -- printenv --version
+print_ver_ printenv
# Without arguments, printenv behaves like env. Some shells provide
# printenv as a builtin, so we must invoke it via "env".
diff --git a/tests/misc/printf b/tests/misc/printf
index b0fe19cdb..b02352ba1 100755
--- a/tests/misc/printf
+++ b/tests/misc/printf
@@ -19,7 +19,7 @@
prog="$abs_top_builddir/src/printf"
. "${srcdir=.}/init.sh"; path_prepend_ ../src
-test "$VERBOSE" = yes && env -- printf --version
+print_ver_ printf
getlimits_
diff --git a/tests/misc/printf-hex b/tests/misc/printf-hex
index 864dc0bb2..4853d392f 100755
--- a/tests/misc/printf-hex
+++ b/tests/misc/printf-hex
@@ -17,7 +17,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
. "${srcdir=.}/init.sh"; path_prepend_ ../src
-test "$VERBOSE" = yes && env -- printf --version
+print_ver_ printf
env printf '\x7e3\n' > out || fail=1
cat <<\EOF > exp
diff --git a/tests/misc/printf-surprise b/tests/misc/printf-surprise
index 53f46b58f..d37a329f5 100755
--- a/tests/misc/printf-surprise
+++ b/tests/misc/printf-surprise
@@ -19,7 +19,7 @@
prog=printf
. "${srcdir=.}/init.sh"; path_prepend_ ../src
-test "$VERBOSE" = yes && env -- printf --version
+print_ver_ printf
require_ulimit_
diff --git a/tests/misc/pwd-long b/tests/misc/pwd-long
index b3d14c6ca..e8b088cd2 100755
--- a/tests/misc/pwd-long
+++ b/tests/misc/pwd-long
@@ -21,7 +21,7 @@
. $srcdir/require-perl
. "${srcdir=.}/init.sh"; path_prepend_ ../src
-test "$VERBOSE" = yes && env -- pwd --version
+print_ver_ pwd
require_readable_root_
diff --git a/tests/misc/pwd-option b/tests/misc/pwd-option
index e01026674..21c5e4000 100755
--- a/tests/misc/pwd-option
+++ b/tests/misc/pwd-option
@@ -17,7 +17,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
. "${srcdir=.}/init.sh"; path_prepend_ ../src
-test "$VERBOSE" = yes && env -- pwd --version
+print_ver_ pwd
mkdir -p a/b || framework_failure
ln -s a/b c || framework_failure