From: Dennis Stosberg <dennis@stosberg.net>
To: git@vger.kernel.org
Subject: t5501-old-fetch-and-upload.sh fails with NO_PYTHON=1
Date: Tue, 11 Apr 2006 19:05:08 +0200 [thread overview]
Message-ID: <20060411170508.G14ba7e47@leonov.stosberg.net> (raw)
Hello,
t/t5501-old-fetch-and-upload.sh fails on Solaris 9 with NO_PYTHON=1.
The test doesn't work correctly on Linux with NO_PYTHON=1, too, but it
doesn't cause a failure there.
When NO_PYTHON=1 is set, t/Makefile passes "--no-python" to the test as
an argument. That causes the $list variable to be set to "--no-python"
instead of "fetch upload". Since that string does not identify a
program to be tested, $pgm remains unset.
On Linux the return code of "which $pgm" is 1 in that case, which
causes the test to do nothing and exit without failure. In contrast,
the return code of "which" without any argument is 0 on Solaris, so
the test is being run and fails.
I have attached a simple fix, but is this test still useful at all?
Regards,
Dennis
diff --git a/t/t5501-old-fetch-and-upload.sh b/t/t5501-old-fetch-and-upload.sh
index 596c88b..df69d97 100755
--- a/t/t5501-old-fetch-and-upload.sh
+++ b/t/t5501-old-fetch-and-upload.sh
@@ -13,10 +13,11 @@ tmp=`pwd`/.tmp$$
retval=0
-if [ -z "$1" ]; then
+tests=`echo "$@"| sed -e 's/--[a-zA-Z\-]*//g'`
+if [ -z "$tests" ]; then
list="fetch upload"
else
- list="$@"
+ list="$tests"
fi
for i in $list; do
next reply other threads:[~2006-04-11 17:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-11 17:05 Dennis Stosberg [this message]
2006-04-11 18:06 ` t5501-old-fetch-and-upload.sh fails with NO_PYTHON=1 Junio C Hamano
2006-04-11 21:31 ` Johannes Schindelin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060411170508.G14ba7e47@leonov.stosberg.net \
--to=dennis@stosberg.net \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox