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

Unified Diff: tools/telemetry/third_party/gsutil/third_party/boto/tests/unit/cloudtrail/test_layer1.py

Issue 1260493004: Revert "Add gsutil 4.13 to telemetry/third_party" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 months 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
Index: tools/telemetry/third_party/gsutil/third_party/boto/tests/unit/cloudtrail/test_layer1.py
diff --git a/tools/telemetry/third_party/gsutil/third_party/boto/tests/unit/cloudtrail/test_layer1.py b/tools/telemetry/third_party/gsutil/third_party/boto/tests/unit/cloudtrail/test_layer1.py
deleted file mode 100644
index 10f6f7022146bd77f3b012d3a4a7927af229b753..0000000000000000000000000000000000000000
--- a/tools/telemetry/third_party/gsutil/third_party/boto/tests/unit/cloudtrail/test_layer1.py
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/usr/bin/env python
-
-import json
-
-from boto.cloudtrail.layer1 import CloudTrailConnection
-from tests.unit import AWSMockServiceTestCase
-
-
-class TestDescribeTrails(AWSMockServiceTestCase):
- connection_class = CloudTrailConnection
-
- def default_body(self):
- return b'''
- {"trailList":
- [
- {
- "IncludeGlobalServiceEvents": false,
- "Name": "test",
- "SnsTopicName": "cloudtrail-1",
- "S3BucketName": "cloudtrail-1"
- }
- ]
- }'''
-
- def test_describe(self):
- self.set_http_response(status_code=200)
- api_response = self.service_connection.describe_trails()
-
- self.assertEqual(1, len(api_response['trailList']))
- self.assertEqual('test', api_response['trailList'][0]['Name'])
-
- self.assert_request_parameters({})
-
- target = self.actual_request.headers['X-Amz-Target']
- self.assertTrue('DescribeTrails' in target)
-
- def test_describe_name_list(self):
- self.set_http_response(status_code=200)
- api_response = self.service_connection.describe_trails(
- trail_name_list=['test'])
-
- self.assertEqual(1, len(api_response['trailList']))
- self.assertEqual('test', api_response['trailList'][0]['Name'])
-
- self.assertEqual(json.dumps({
- 'trailNameList': ['test']
- }), self.actual_request.body.decode('utf-8'))
-
- target = self.actual_request.headers['X-Amz-Target']
- self.assertTrue('DescribeTrails' in target)
-
-
-class TestCreateTrail(AWSMockServiceTestCase):
- connection_class = CloudTrailConnection
-
- def default_body(self):
- return b'''
- {"trail":
- {
- "IncludeGlobalServiceEvents": false,
- "Name": "test",
- "SnsTopicName": "cloudtrail-1",
- "S3BucketName": "cloudtrail-1"
- }
- }'''
-
- def test_create(self):
- self.set_http_response(status_code=200)
-
- api_response = self.service_connection.create_trail(
- 'test', 'cloudtrail-1', sns_topic_name='cloudtrail-1',
- include_global_service_events=False)
-
- self.assertEqual('test', api_response['trail']['Name'])
- self.assertEqual('cloudtrail-1', api_response['trail']['S3BucketName'])
- self.assertEqual('cloudtrail-1', api_response['trail']['SnsTopicName'])
- self.assertEqual(False,
- api_response['trail']['IncludeGlobalServiceEvents'])
-
- target = self.actual_request.headers['X-Amz-Target']
- self.assertTrue('CreateTrail' in target)

Powered by Google App Engine
This is Rietveld 408576698