From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS6939 64.71.128.0/18 X-Spam-Status: No, score=-1.9 required=3.0 tests=AWL,BAYES_00, MSGID_FROM_MTA_HEADER shortcircuit=no autolearn=unavailable version=3.3.2 Path: news.gmane.org!not-for-mail From: Eric Wong Newsgroups: gmane.comp.lang.ruby.raindrops.general Subject: [PATCH 1/3] test_watcher: fix incorrect request/date comparison Date: Mon, 18 Jun 2012 14:20:43 -0700 Message-ID: <1340054445-29631-2-git-send-email-normalperson@yhbt.net> References: <1340054445-29631-1-git-send-email-normalperson@yhbt.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1340054466 14989 80.91.229.3 (18 Jun 2012 21:21:06 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 18 Jun 2012 21:21:06 +0000 (UTC) To: raindrops@librelist.org Original-X-From: raindrops@librelist.org Mon Jun 18 23:21:05 2012 Return-path: Envelope-to: gclrrg-raindrops@m.gmane.org List-Archive: List-Help: List-Id: List-Post: List-Subscribe: List-Unsubscribe: Precedence: list Original-Sender: raindrops@librelist.org Xref: news.gmane.org gmane.comp.lang.ruby.raindrops.general:90 Archived-At: Received: from zedshaw.xen.prgmr.com ([64.71.167.205]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SgjNg-0004Z5-D0 for gclrrg-raindrops@m.gmane.org; Mon, 18 Jun 2012 23:21:04 +0200 Received: from zedshaw.xen.prgmr.com (localhost [IPv6:::1]) by zedshaw.xen.prgmr.com (Postfix) with ESMTP id C167321DDE1 for ; Mon, 18 Jun 2012 21:29:24 +0000 (UTC) It makes no sense to compare peak times of different queues (active vs queued) against each other. --- test/test_watcher.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/test/test_watcher.rb b/test/test_watcher.rb index 056a3bf..5e45dcd 100644 --- a/test/test_watcher.rb +++ b/test/test_watcher.rb @@ -156,6 +156,7 @@ class TestWatcher < Test::Unit::TestCase @ios << @srv.accept assert_raises(Errno::EAGAIN) { @srv.accept_nonblock } sleep 0.1 + env = @req.class.env_for "/queued/#@addr.txt" status, headers, body = @app.call(env.dup) assert headers["X-Last-Peak-At"], headers.inspect assert_nothing_raised { Time.parse(headers["X-Last-Peak-At"]) } -- 1.7.11.rc0.55.gb2478aa