[PATCH 3/4] test: extract and flag second rounding tests as broken
authorJani Nikula <jani@nikula.org>
Mon, 2 Mar 2015 17:47:03 +0000 (19:47 +0200)
committerW. Trevor King <wking@tremily.us>
Sat, 20 Aug 2016 21:48:12 +0000 (14:48 -0700)
89/5a2feb12fda157e624dee279d6af4eef7db055 [new file with mode: 0644]

diff --git a/89/5a2feb12fda157e624dee279d6af4eef7db055 b/89/5a2feb12fda157e624dee279d6af4eef7db055
new file mode 100644 (file)
index 0000000..2ccab64
--- /dev/null
@@ -0,0 +1,110 @@
+Return-Path: <jani@nikula.org>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id A4D50429E41\r
+       for <notmuch@notmuchmail.org>; Mon,  2 Mar 2015 10:30:57 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 1.738\r
+X-Spam-Level: *\r
+X-Spam-Status: No, score=1.738 tagged_above=-999 required=5\r
+       tests=[DNS_FROM_AHBL_RHSBL=2.438, RCVD_IN_DNSWL_LOW=-0.7]\r
+       autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id CS-fSdGxA-Iz for <notmuch@notmuchmail.org>;\r
+       Mon,  2 Mar 2015 10:30:54 -0800 (PST)\r
+Received: from mail-wg0-f50.google.com (mail-wg0-f50.google.com\r
+ [74.125.82.50])       (using TLSv1 with cipher RC4-SHA (128/128 bits))        (No client\r
+ certificate requested)        by olra.theworths.org (Postfix) with ESMTPS id\r
+ 17AEB414B86   for <notmuch@notmuchmail.org>; Mon,  2 Mar 2015 09:49:32 -0800\r
+ (PST)\r
+Received: by wghn12 with SMTP id n12so35093173wgh.1\r
+       for <notmuch@notmuchmail.org>; Mon, 02 Mar 2015 09:46:52 -0800 (PST)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+       d=1e100.net; s=20130820;\r
+       h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\r
+       :references;\r
+       bh=YYGPQwZyQLwQnR/FCFztPCauFxWqujng3ah7GFYV5ZE=;\r
+       b=YooDChFDJoB1zbShA8E2h8cInacJ6adWJbfOmdykQJg/Yy4HuKJSUH0/9MCZ0vhkgj\r
+       acAHVzYpmHBuuwUqqDmH102DEdksQQ3IgHC7KtJJLFCDlseI3CRGna3dDMx9yoPpFgOw\r
+       tJEP7+XCk7o2QDjdD+PwP2ROnbWv2aUtrgJpkMUs6qXzkjqNRthUDwcCZa9hLK3J6cEW\r
+       YfyuENXnQxvWaMAMEV7awJHTf+eTIb8HWMRHXEfs3+nORMRLHJvLqYSGVGWxM076rJX3\r
+       9/WUo/Es8GHLKX4nMuzqYp3HsqzmmPxhEgrhoiBGMrm7UHqE77UaCRzalD8YQH+2LMsc\r
+       QFWw==\r
+X-Gm-Message-State:\r
+ ALoCoQkemXStd1j8mIo65X2KD2OzWaGIQqnO38CLvCDg+g68ebc4QushqgGBrBIEN8U6ZkuYd/6N\r
+X-Received: by 10.180.82.103 with SMTP id h7mr19861933wiy.30.1425318412010;\r
+       Mon, 02 Mar 2015 09:46:52 -0800 (PST)\r
+Received: from localhost (mobile-internet-bcee3b-76.dhcp.inet.fi.\r
+       [188.238.59.76]) by mx.google.com with ESMTPSA id\r
+       s19sm16990950wik.18.2015.03.02.09.46.50\r
+       (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\r
+       Mon, 02 Mar 2015 09:46:51 -0800 (PST)\r
+From: Jani Nikula <jani@nikula.org>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH 3/4] test: extract and flag second rounding tests as broken\r
+Date: Mon,  2 Mar 2015 19:47:03 +0200\r
+Message-Id: <1425318424-27017-3-git-send-email-jani@nikula.org>\r
+X-Mailer: git-send-email 2.1.4\r
+In-Reply-To: <1425318424-27017-1-git-send-email-jani@nikula.org>\r
+References: <1425318424-27017-1-git-send-email-jani@nikula.org>\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 02 Mar 2015 18:30:58 -0000\r
+\r
+Extract and add some more tests relating to rounding seconds into a\r
+separate subtest, and flag it as broken. If seconds are not specified,\r
+the time is not set or rounded according to the interface defined in\r
+parse-time-string/parse-time-string.h. Instead, seconds are always set\r
+to 00 in reality, which is broken.\r
+---\r
+ test/T490-parse-time-string.sh | 16 ++++++++++++++--\r
+ 1 file changed, 14 insertions(+), 2 deletions(-)\r
+\r
+diff --git a/test/T490-parse-time-string.sh b/test/T490-parse-time-string.sh\r
+index ca3ecb4036ed..9247bdf89543 100755\r
+--- a/test/T490-parse-time-string.sh\r
++++ b/test/T490-parse-time-string.sh\r
+@@ -40,8 +40,6 @@ two mo       ==> Thu Nov 11 12:13:14 +0000 2010\r
+ 5m           ==> Tue Jan 11 12:08:14 +0000 2011\r
+ dozen mi     ==> Tue Jan 11 12:01:14 +0000 2011\r
+ 8am          ==> Tue Jan 11 08:00:00 +0000 2011\r
+-9:15         ==> Tue Jan 11 09:15:00 +0000 2011\r
+-12:34        ==> Tue Jan 11 12:34:00 +0000 2011\r
+ monday       ==> Mon Jan 10 12:13:14 +0000 2011\r
+ yesterday    ==> Mon Jan 10 12:13:14 +0000 2011\r
+ tomorrow     ==> ERROR: KEYWORD\r
+@@ -80,4 +78,18 @@ EOF\r
+ ${TEST_DIRECTORY}/parse-time --ref=${REFERENCE} < INPUT > OUTPUT\r
+ test_expect_equal_file INPUT OUTPUT\r
\r
++test_begin_subtest "Second rounding tests"\r
++test_subtest_known_broken\r
++REFERENCE=$(_date Tue Jan 11 12:13:14 +0000 2011)\r
++cat <<EOF > INPUT\r
++9:15         ==> Tue Jan 11 09:15:14 +0000 2011\r
++12:34        ==> Tue Jan 11 12:34:14 +0000 2011\r
++10:30        ==> Tue Jan 11 10:30:14 +0000 2011\r
++10:30        ==^> Tue Jan 11 10:30:59 +0000 2011\r
++10:30        ==^^> Tue Jan 11 10:31:00 +0000 2011\r
++10:30        ==_> Tue Jan 11 10:30:00 +0000 2011\r
++EOF\r
++${TEST_DIRECTORY}/parse-time --ref=${REFERENCE} < INPUT > OUTPUT\r
++test_expect_equal_file INPUT OUTPUT\r
++\r
+ test_done\r
+-- \r
+2.1.4\r
+\r