예제 #1
0
 def test_should_allow_milliseconds_in_expiration(self):
     """Moto has milliseconds in the expiration date, AWS does not"""
     credentials = {'test_role': '{"Expiration": "1970-01-01T00:00:59.123Z"}'}
     scheduler = Scheduler(credentials, None)
     expected = 59
     received = scheduler.extract_refresh_delta()
     self.assertEqual(expected, received)
예제 #2
0
 def test_should_extract_correct_seconds_from_credentials(self):
     credentials = {'test_role': '{"Expiration": "1970-01-01T00:00:59Z"}'}
     scheduler = Scheduler(credentials, None)
     expected = 59
     received = scheduler.extract_refresh_delta()
     self.assertEqual(expected, received)