Return-Path: X-Original-To: apmail-couchdb-commits-archive@www.apache.org Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8C9B297CA for ; Wed, 25 Apr 2012 22:18:26 +0000 (UTC) Received: (qmail 64454 invoked by uid 500); 25 Apr 2012 22:18:26 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 64339 invoked by uid 500); 25 Apr 2012 22:18:26 -0000 Mailing-List: contact commits-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list commits@couchdb.apache.org Received: (qmail 64241 invoked by uid 99); 25 Apr 2012 22:18:25 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Apr 2012 22:18:25 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 18B68E58A; Wed, 25 Apr 2012 22:18:24 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: davisp@apache.org To: commits@couchdb.apache.org X-Mailer: ASF-Git Admin Mailer Subject: [3/8] git commit: Fix random failures in replication.js test Message-Id: <20120425221825.18B68E58A@tyr.zones.apache.org> Date: Wed, 25 Apr 2012 22:18:24 +0000 (UTC) Fix random failures in replication.js test This should fix the random failures for the 'expected "25" got "31" error message that pops up occasionally. If my hunch is correct when we remove the two docs from the source db its possible to get the writes on the target out of order depending on a race condition. This just sleeps a bit in between the deletions to try and reduce that possibility. I haven't spotted this error after applying this patch. Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/3beac4e7 Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/3beac4e7 Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/3beac4e7 Branch: refs/heads/master Commit: 3beac4e7d6e247af09d087fa53bac85c4b2f7c38 Parents: 08071a8 Author: Paul Joseph Davis Authored: Sat Mar 24 20:17:28 2012 -0500 Committer: Paul Joseph Davis Committed: Wed Apr 25 16:54:08 2012 -0500 ---------------------------------------------------------------------- share/www/script/test/replication.js | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb/blob/3beac4e7/share/www/script/test/replication.js ---------------------------------------------------------------------- diff --git a/share/www/script/test/replication.js b/share/www/script/test/replication.js index 224f589..f54ffff 100644 --- a/share/www/script/test/replication.js +++ b/share/www/script/test/replication.js @@ -1280,6 +1280,7 @@ couchTests.replication = function(debug) { // delete docs from source TEquals(true, sourceDb.deleteDoc(newDocs[0]).ok); + wait(1000); TEquals(true, sourceDb.deleteDoc(newDocs[6]).ok); waitForSeq(sourceDb, targetDb);