Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(13)

Unified Diff: third_party/boto/tests/unit/swf/test_layer2_base.py

Issue 698893003: Update checked in version of gsutil to version 4.6 (Closed) Base URL: http://dart.googlecode.com/svn/third_party/gsutil/
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/boto/tests/unit/sts/test_connection.py ('k') | third_party/boto/tests/unit/test_connection.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/boto/tests/unit/swf/test_layer2_base.py
===================================================================
--- third_party/boto/tests/unit/swf/test_layer2_base.py (revision 0)
+++ third_party/boto/tests/unit/swf/test_layer2_base.py (revision 0)
@@ -0,0 +1,31 @@
+import boto.swf.layer2
+from boto.swf.layer2 import SWFBase
+from tests.unit import unittest
+from mock import Mock
+
+
+MOCK_DOMAIN = 'Mock'
+MOCK_ACCESS_KEY = 'inheritable access key'
+MOCK_SECRET_KEY = 'inheritable secret key'
+MOCK_REGION = 'Mock Region'
+
+
+class TestBase(unittest.TestCase):
+ """
+ Test for SWFBase.
+ """
+ def setUp(self):
+ boto.swf.layer2.Layer1 = Mock()
+ self.swf_base = SWFBase(
+ domain=MOCK_DOMAIN, aws_access_key_id=MOCK_ACCESS_KEY,
+ aws_secret_access_key=MOCK_SECRET_KEY, region=MOCK_REGION
+ )
+
+ def test_instantiation(self):
+ self.assertEquals(MOCK_DOMAIN, self.swf_base.domain)
+ self.assertEquals(MOCK_ACCESS_KEY, self.swf_base.aws_access_key_id)
+ self.assertEquals(MOCK_SECRET_KEY,
+ self.swf_base.aws_secret_access_key)
+ self.assertEquals(MOCK_REGION, self.swf_base.region)
+ boto.swf.layer2.Layer1.assert_called_with(
+ MOCK_ACCESS_KEY, MOCK_SECRET_KEY, region=MOCK_REGION)
Property changes on: third_party/boto/tests/unit/swf/test_layer2_base.py
___________________________________________________________________
Added: svn:eol-style
+ LF
« no previous file with comments | « third_party/boto/tests/unit/sts/test_connection.py ('k') | third_party/boto/tests/unit/test_connection.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698