From: Michael J Gruber <git@grubix.eu>
To: git@vger.kernel.org
Cc: Adam Dinwoodie <adam@dinwoodie.org>,
Junio C Hamano <gitster@pobox.com>, Jeff King <peff@peff.net>,
Johannes Schindelin <Johannes.Schindelin@gmx.de>,
Ramsay Jones <ramsay@ramsayjones.plus.com>
Subject: [PATCH 2/2] test-lib: ulimit does not limit on CYGWIN and MINGW
Date: Thu, 14 Sep 2017 16:52:34 +0200 [thread overview]
Message-ID: <00b6d2a5508520635956da1d2db656bca126cd1a.1505400392.git.git@grubix.eu> (raw)
In-Reply-To: <alpine.DEB.2.21.1.1709141440510.4132@virtualbox>
In-Reply-To: <4482ae18370f3e759bf98f71e15eaab19fdd009a.1505400392.git.git@grubix.eu>
ulimit succeeds (by return value) but does not limit on some systems.
Set ulimit() to false on these systems so that we do not rely on its
output nor effect. As an intended side-effect, ulimit based
prerequisites are set correctly (to "not-have") on these systems.
Reported-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Reported-by: Adam Dinwoodie <adam@dinwoodie.org>
Reported-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Michael J Gruber <git@grubix.eu>
---
This is independent of my series, but should best go before so that no
ulimit based test is run on CYGWIN and MINGW.
It follows the basic assumption that a tool like ulimit is either
present and functional or not present; and that we work around by
defines or such when that assumption is broken.
(Alternatively, we could set ULIMT_LIMITS or so and depend on that.)
t/test-lib.sh | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/t/test-lib.sh b/t/test-lib.sh
index b8a0b05102..f6ac60d487 100644
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -998,6 +998,10 @@ case $uname_s in
mkfifo () {
false
}
+ # ulimit succeeds but does not limit
+ ulimit () {
+ false
+ }
# no POSIX permissions
# backslashes in pathspec are converted to '/'
# exec does not inherit the PID
@@ -1012,6 +1016,10 @@ case $uname_s in
mkfifo () {
false
}
+ # ulimit succeeds but does not limit
+ ulimit () {
+ false
+ }
test_set_prereq POSIXPERM
test_set_prereq EXECKEEPSPID
test_set_prereq CYGWIN
--
2.14.1.712.gda4591c8a2
next prev parent reply other threads:[~2017-09-14 14:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-13 19:00 [PATCH] test-lib: don't use ulimit in test prerequisites on cygwin Ramsay Jones
2017-09-13 19:20 ` Jonathan Nieder
2017-09-14 8:13 ` Michael J Gruber
2017-09-14 12:54 ` Johannes Schindelin
2017-09-14 14:52 ` [PATCH 1/2] test-lib: group system specific FIFO tests by system Michael J Gruber
2017-09-14 14:52 ` Michael J Gruber [this message]
2017-09-14 17:31 ` [PATCH 2/2] test-lib: ulimit does not limit on CYGWIN and MINGW Ramsay Jones
2017-09-14 22:21 ` [PATCH 1/2] test-lib: group system specific FIFO tests by system Johannes Schindelin
2017-09-15 10:31 ` Michael J Gruber
2017-09-15 16:38 ` Ramsay Jones
2017-09-15 19:32 ` 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=00b6d2a5508520635956da1d2db656bca126cd1a.1505400392.git.git@grubix.eu \
--to=git@grubix.eu \
--cc=Johannes.Schindelin@gmx.de \
--cc=adam@dinwoodie.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=peff@peff.net \
--cc=ramsay@ramsayjones.plus.com \
/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;
as well as URLs for NNTP newsgroup(s).