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

Side by Side Diff: third_party/boto/tests/unit/cloudformation/test_stack.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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 import datetime 2 import datetime
3 import xml.sax 3 import xml.sax
4 import unittest 4 import unittest
5 import boto.handler 5 import boto.handler
6 import boto.resultset 6 import boto.resultset
7 import boto.cloudformation 7 import boto.cloudformation
8 8
9 SAMPLE_XML = r""" 9 SAMPLE_XML = r"""
10 <DescribeStacksResponse xmlns="http://cloudformation.amazonaws.com/doc/2010-05-1 5/"> 10 <DescribeStacksResponse xmlns="http://cloudformation.amazonaws.com/doc/2010-05-1 5/">
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 self.assertEqual( 194 self.assertEqual(
195 timestamp_2, 195 timestamp_2,
196 datetime.datetime(2011, 3, 5, 19, 57, 58, 161616) 196 datetime.datetime(2011, 3, 5, 19, 57, 58, 161616)
197 ) 197 )
198 timestamp_3 = rs[1].deletion_time 198 timestamp_3 = rs[1].deletion_time
199 self.assertEqual( 199 self.assertEqual(
200 timestamp_3, 200 timestamp_3,
201 datetime.datetime(2011, 3, 10, 16, 20, 51, 575757) 201 datetime.datetime(2011, 3, 10, 16, 20, 51, 575757)
202 ) 202 )
203 203
204 def test_list_stacks_time_with_millis(self): 204 def test_list_stacks_time_with_millis_again(self):
205 rs = boto.resultset.ResultSet([ 205 rs = boto.resultset.ResultSet([
206 ('member', boto.cloudformation.stack.StackResourceSummary) 206 ('member', boto.cloudformation.stack.StackResourceSummary)
207 ]) 207 ])
208 h = boto.handler.XmlHandler(rs, None) 208 h = boto.handler.XmlHandler(rs, None)
209 xml.sax.parseString(LIST_STACK_RESOURCES_XML, h) 209 xml.sax.parseString(LIST_STACK_RESOURCES_XML, h)
210 timestamp_1 = rs[0].last_updated_time 210 timestamp_1 = rs[0].last_updated_time
211 self.assertEqual( 211 self.assertEqual(
212 timestamp_1, 212 timestamp_1,
213 datetime.datetime(2011, 6, 21, 20, 15, 58) 213 datetime.datetime(2011, 6, 21, 20, 15, 58)
214 ) 214 )
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
247 rs = boto.resultset.ResultSet([('member', boto.cloudformation.stack.Stac k)]) 247 rs = boto.resultset.ResultSet([('member', boto.cloudformation.stack.Stac k)])
248 h = boto.handler.XmlHandler(rs, None) 248 h = boto.handler.XmlHandler(rs, None)
249 sample_xml_upper = SAMPLE_XML.replace('false', 'True') 249 sample_xml_upper = SAMPLE_XML.replace('false', 'True')
250 xml.sax.parseString(sample_xml_upper, h) 250 xml.sax.parseString(sample_xml_upper, h)
251 disable_rollback = rs[0].disable_rollback 251 disable_rollback = rs[0].disable_rollback
252 self.assertTrue(disable_rollback) 252 self.assertTrue(disable_rollback)
253 253
254 254
255 if __name__ == '__main__': 255 if __name__ == '__main__':
256 unittest.main() 256 unittest.main()
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698