commit e8f2241524137230e22d445732ea79484dd6cd83
Author: Jim Meyering <meyering(a)redhat.com>
Date: Fri Feb 24 17:41:25 2012 +0100
iwhd --auto: increase timeout to allow for longer mongod start-up delay
These changes avoid the failure of the t/auto test when run via
"make -j$N check" for nontrivial $N.
* auto.c (auto_wait_mongod): Increase timeout from 20s to 30s,
to accommodate longer delay required for mongod to start, in case it
performs journal initialization, as is now the default in Fedora 16.
* t/auto: Likewise.
auto.c | 2 +-
t/auto | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/auto.c b/auto.c
index cd54d88..64f6a9a 100644
--- a/auto.c
+++ b/auto.c
@@ -184,7 +184,7 @@ auto_wait_mongod(void)
rc = auto_test_mongod();
if (rc == 0)
break;
- if (time(NULL) >= start_time + 20) {
+ if (time(NULL) >= start_time + 30) {
log_msg(0, _("failed to verify mongod using port %s"),
auto_arg_port);
return -1;
diff --git a/t/auto b/t/auto
index c8d4ee3..5f7092d 100755
--- a/t/auto
+++ b/t/auto
@@ -24,7 +24,7 @@ cleanup_() { kill $iwhd_pid; }
# Wait longer than usual (i.e., don't use wait_for_mongo), since this
# mongo daemon was started via iwhd itself, and not with $mongo_opt
-wait_for .1 100 'mongo localhost:$m_port < /dev/null' \
+wait_for .1 300 'mongo localhost:$m_port < /dev/null' \
|| framework_failure_ mongod failed to start
# Wait for up to 20 seconds for iwhd to begin listening on $port.
wait_for .1 200 "curl -s
http://localhost:$port" \