Return-Path: X-Original-To: apmail-climate-commits-archive@minotaur.apache.org Delivered-To: apmail-climate-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2DBBE10B32 for ; Fri, 16 Aug 2013 14:43:05 +0000 (UTC) Received: (qmail 78820 invoked by uid 500); 16 Aug 2013 14:43:05 -0000 Delivered-To: apmail-climate-commits-archive@climate.apache.org Received: (qmail 78787 invoked by uid 500); 16 Aug 2013 14:43:04 -0000 Mailing-List: contact commits-help@climate.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@climate.incubator.apache.org Delivered-To: mailing list commits@climate.incubator.apache.org Received: (qmail 78776 invoked by uid 99); 16 Aug 2013 14:43:04 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Aug 2013 14:43:04 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Aug 2013 14:43:02 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 08A7023888E4; Fri, 16 Aug 2013 14:42:41 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1514737 - /incubator/climate/branches/RefactorInput/ocw/tests/test_dataset.py Date: Fri, 16 Aug 2013 14:42:40 -0000 To: commits@climate.incubator.apache.org From: joyce@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20130816144241.08A7023888E4@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: joyce Date: Fri Aug 16 14:42:40 2013 New Revision: 1514737 URL: http://svn.apache.org/r1514737 Log: CLIMATE-254 - Cleaning up tests Modified: incubator/climate/branches/RefactorInput/ocw/tests/test_dataset.py Modified: incubator/climate/branches/RefactorInput/ocw/tests/test_dataset.py URL: http://svn.apache.org/viewvc/incubator/climate/branches/RefactorInput/ocw/tests/test_dataset.py?rev=1514737&r1=1514736&r2=1514737&view=diff ============================================================================== --- incubator/climate/branches/RefactorInput/ocw/tests/test_dataset.py (original) +++ incubator/climate/branches/RefactorInput/ocw/tests/test_dataset.py Fri Aug 16 14:42:40 2013 @@ -83,6 +83,14 @@ class TestBounds(unittest.TestCase): dt.datetime(2000, 1, 1), # Start time dt.datetime(2002, 1, 1)) # End time + # Latitude tests + def test_inverted_min_max_lat(self): + with self.assertRaises(ValueError): + self.bounds.lat_min = 81 + + with self.assertRaises(ValueError): + self.bounds.lat_max = -81 + # Lat Min def test_out_of_bounds_lat_min(self): with self.assertRaises(ValueError): @@ -91,10 +99,6 @@ class TestBounds(unittest.TestCase): with self.assertRaises(ValueError): self.bounds.lat_min = 91 - def test_inverted_min_max_lat(self): - with self.assertRaises(ValueError): - self.bounds.lat_min = 81 - # Lat Max def test_out_of_bounds_lat_max(self): with self.assertRaises(ValueError): @@ -103,9 +107,13 @@ class TestBounds(unittest.TestCase): with self.assertRaises(ValueError): self.bounds.lat_max = 91 - def test_inverted_max_max_lat(self): + # Longitude tests + def test_inverted_max_max_lon(self): with self.assertRaises(ValueError): - self.bounds.lat_max = -81 + self.bounds.lon_min = 161 + + with self.assertRaises(ValueError): + self.bounds.lon_max = -161 # Lon Min def test_out_of_bounds_lon_min(self): @@ -115,10 +123,6 @@ class TestBounds(unittest.TestCase): with self.assertRaises(ValueError): self.bounds.lon_min = 181 - def test_inverted_max_max_lon(self): - with self.assertRaises(ValueError): - self.bounds.lon_min = 161 - # Lon Max def test_out_of_bounds_lon_max(self): with self.assertRaises(ValueError): @@ -127,9 +131,5 @@ class TestBounds(unittest.TestCase): with self.assertRaises(ValueError): self.bounds.lon_max = 181 - def test_inverted_max_max_lon(self): - with self.assertRaises(ValueError): - self.bounds.lon_max = -161 - if __name__ == '__main__': unittest.main()