[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [SIMPLE PATCH] {maint} Extend tests on `--help' and `--version' opti
From: |
Stefano Lattarini |
Subject: |
Re: [SIMPLE PATCH] {maint} Extend tests on `--help' and `--version' options. |
Date: |
Sat, 2 Oct 2010 19:35:34 +0200 |
User-agent: |
KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) |
On Saturday 02 October 2010, Ralf Wildenhues wrote:
> * Stefano Lattarini wrote on Sun, Sep 26, 2010 at 04:48:01PM CEST:
> > Attached is what I pushed. I also merged to master and
> > branch-1.11.
> >
> > From a82bc0d5cfea18fc96476c23a4fb2d458af09c89 Mon Sep 17 00:00:00
> > 2001 From: Stefano Lattarini <address@hidden>
> > Date: Sat, 25 Sep 2010 17:07:27 +0200
> > Subject: [PATCH] Extend tests on `--help' and `--version'
> > options.
> >
> > * tests/help.test: Create a new empty directory and chdir into
> > it, rather than removing already present files. Run the aclocal
> > and automake wrapper scripts directly, instead of relying on
> > $AUTOMAKE and $ACLOCAL. Be sure to correctly match literal dots
> > in aclocal's and automake's stderr. Add a trailing `:' command.
> > * tests/help2.test: New test, checking that options `--help' and
> > `--version' works in directories with broken `configure.in'.
> > * tests/help3.test: New test, checking that options `--help' and
> > `--version' take precedence on the other options.
> > * tests/help4.test: New test, checking that the first among the
> > `--help' and `--version' options to be specified on the command
> > line wins.
> > * tests/Makefile.am (TESTS): Updated.
>
> This patch breaks maintainer-check.
The attached patch fixes the breakage. OK for maint?
(Still, I don't like having to tweak test script with needless quoting
to avoid spurious maintcheck failures. Oh well.)
Regards,
Stefano
From 5a98218e985f1d215ac61590d9ad5b08d6f62a7a Mon Sep 17 00:00:00 2001
From: Stefano Lattarini <address@hidden>
Date: Sat, 2 Oct 2010 19:33:44 +0200
Subject: [PATCH] Fix maintainer-check failure in `help*.test' tests.
* tests/help.test: Use creative quoting to avoid maintainer-check
failure.
* tests/help2.test: Likewise.
* tests/help3.test: Likewise.
* tests/help4.test: Likewise.
---
ChangeLog | 9 +++++++++
tests/help.test | 12 ++++++------
tests/help2.test | 8 ++++----
tests/help3.test | 12 ++++++------
tests/help4.test | 8 ++++----
5 files changed, 29 insertions(+), 20 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 82044a3..cbe703f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2010-10-02 Stefano Lattarini <address@hidden>
+
+ Fix maintainer-check failure in `help*.test' tests.
+ * tests/help.test: Use creative quoting to avoid maintainer-check
+ failure.
+ * tests/help2.test: Likewise.
+ * tests/help3.test: Likewise.
+ * tests/help4.test: Likewise.
+
2010-10-02 Ralf Wildenhues <address@hidden>
Revert "parallel-tests: avoid command-line length limit issue."
diff --git a/tests/help.test b/tests/help.test
index ddeb92f..3311c9c 100755
--- a/tests/help.test
+++ b/tests/help.test
@@ -25,18 +25,18 @@ set -e
mkdir emptydir
cd emptydir
-aclocal-$APIVERSION --version
-aclocal-$APIVERSION --help
-automake-$APIVERSION --version
-automake-$APIVERSION --help
+"aclocal-$APIVERSION" --version
+"aclocal-$APIVERSION" --help
+"automake-$APIVERSION" --version
+"automake-$APIVERSION" --help
# Sanity checks: aclocal and automake cannot work without configure.ac
# or configure.in.
-aclocal-$APIVERSION 2>stderr && { cat stderr >&2; Exit 1; }
+"aclocal-$APIVERSION" 2>stderr && { cat stderr >&2; Exit 1; }
cat stderr >&2
$FGREP configure.ac stderr
$FGREP configure.in stderr
-automake-$APIVERSION 2>stderr && { cat stderr >&2; Exit 1; }
+"automake-$APIVERSION" 2>stderr && { cat stderr >&2; Exit 1; }
cat stderr >&2
$FGREP configure.ac stderr
$FGREP configure.in stderr
diff --git a/tests/help2.test b/tests/help2.test
index 014f187..49e238f 100755
--- a/tests/help2.test
+++ b/tests/help2.test
@@ -26,14 +26,14 @@ cd cleandir
echo '[' > configure.in
-automake-$APIVERSION --version
-automake-$APIVERSION --help
+"automake-$APIVERSION" --version
+"automake-$APIVERSION" --help
# aclocal and automake cannot work without configure.ac or configure.in
-aclocal-$APIVERSION 2>stderr && { cat stderr >&2; Exit 1; }
+"aclocal-$APIVERSION" 2>stderr && { cat stderr >&2; Exit 1; }
cat stderr >&2
$FGREP configure.in stderr
-automake-$APIVERSION 2>stderr && { cat stderr >&2; Exit 1; }
+"automake-$APIVERSION" 2>stderr && { cat stderr >&2; Exit 1; }
cat stderr >&2
$FGREP configure.in stderr
diff --git a/tests/help3.test b/tests/help3.test
index 8e9e76f..529d6dd 100755
--- a/tests/help3.test
+++ b/tests/help3.test
@@ -36,22 +36,22 @@ cat > Makefile.am <<END
pkgdata_DATA =
END
-aclocal-$APIVERSION --force --help --output=foo.m4
+"aclocal-$APIVERSION" --force --help --output=foo.m4
test ! -r foo.m4
-aclocal-$APIVERSION --output=foo.m4 --version --force
+"aclocal-$APIVERSION" --output=foo.m4 --version --force
test ! -r foo.m4
# Sanity check.
-aclocal-$APIVERSION --output=foo.m4 --force
+"aclocal-$APIVERSION" --output=foo.m4 --force
test -f foo.m4
mv -f foo.m4 aclocal.m4 # automake will need aclocal.m4
-automake-$APIVERSION --add-missing --help --copy
+"automake-$APIVERSION" --add-missing --help --copy
test ! -r install-sh
-automake-$APIVERSION --copy --version --add-mising
+"automake-$APIVERSION" --copy --version --add-mising
test ! -r install-sh
# Sanity check.
-automake-$APIVERSION --add-missing --copy
+"automake-$APIVERSION" --add-missing --copy
test -f install-sh
:
diff --git a/tests/help4.test b/tests/help4.test
index 906e508..48cdbe2 100755
--- a/tests/help4.test
+++ b/tests/help4.test
@@ -28,22 +28,22 @@ cd emptydir
escape_dots () { sed 's/\./\\./g'; } # avoid issues with `\' in backquotes
apiversion_rx=`echo "$APIVERSION" | escape_dots`
-aclocal-$APIVERSION --version --help >stdout || { cat stdout; Exit 1; }
+"aclocal-$APIVERSION" --version --help >stdout || { cat stdout; Exit 1; }
cat stdout
grep "^aclocal.*$apiversion_rx" stdout
grep "^Usage" stdout && Exit 1
-aclocal-$APIVERSION --help --version >stdout || { cat stdout; Exit 1; }
+"aclocal-$APIVERSION" --help --version >stdout || { cat stdout; Exit 1; }
cat stdout
grep "^Usage" stdout
grep "^aclocal.*$apiversion_rx" stdout && Exit 1
-automake-$APIVERSION --version --help >stdout || { cat stdout; Exit 1; }
+"automake-$APIVERSION" --version --help >stdout || { cat stdout; Exit 1; }
cat stdout
grep "^automake.*$apiversion_rx" stdout
grep "^Usage" stdout && Exit 1
-automake-$APIVERSION --help --version >stdout || { cat stdout; Exit 1; }
+"automake-$APIVERSION" --help --version >stdout || { cat stdout; Exit 1; }
cat stdout
grep "^Usage" stdout
grep "^automake.*$apiversion_rx" stdout && Exit 1
--
1.7.1