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

Unified Diff: tests/download_from_google_storage_unittests.py

Issue 76583002: Add no_auth flag to skip auth checking for buckets that don't require it. Also fix tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Set the boto file to empty if --no_auth is specified Created 7 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 | « download_from_google_storage.py ('k') | tests/upload_to_google_storage_unittests.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/download_from_google_storage_unittests.py
diff --git a/tests/download_from_google_storage_unittests.py b/tests/download_from_google_storage_unittests.py
index 24cc7997d6ba0864d1a06878bf8d3ff1599ff1c5..77dd40a67e8174c6d3daf0df8fe88be2fa054264 100755
--- a/tests/download_from_google_storage_unittests.py
+++ b/tests/download_from_google_storage_unittests.py
@@ -82,7 +82,7 @@ class GstoolsUnitTests(unittest.TestCase):
self.assertEqual(err_lines[0], 'gsutil version 3.25')
self.assertEqual(
err_lines[1],
- 'checksum 010822c61d38d70ac23600bc955fccf5 (OK)')
+ 'checksum c9cffb512f467c0aa54880788b9ee6ca (OK)')
def test_get_sha1(self):
lorem_ipsum = os.path.join(self.base_path, 'lorem_ipsum.txt')
@@ -179,6 +179,12 @@ class DownloadTests(unittest.TestCase):
('ls', input_filename)),
('check_call',
('cp', '-q', input_filename, output_filename))]
+ if sys.platform != 'win32':
+ expected_calls.append(
+ ('check_call',
+ ('ls',
+ '-L',
+ 'gs://sometesturl/7871c8e24da15bad8b0be2c36edc9dc77e37727f')))
expected_output = [
'0> Downloading %s...' % output_filename]
expected_ret_codes = []
@@ -251,6 +257,12 @@ class DownloadTests(unittest.TestCase):
('check_call',
('cp', '-q', input_filename, output_filename))
]
+ if sys.platform != 'win32':
+ expected_calls.append(
+ ('check_call',
+ ('ls',
+ '-L',
+ 'gs://sometesturl/7871c8e24da15bad8b0be2c36edc9dc77e37727f')))
self.assertEqual(self.gsutil.history, expected_calls)
self.assertEqual(code, 101)
@@ -274,6 +286,12 @@ class DownloadTests(unittest.TestCase):
('ls', input_filename)),
('check_call',
('cp', '-q', input_filename, output_filename))]
+ if sys.platform != 'win32':
+ expected_calls.append(
+ ('check_call',
+ ('ls',
+ '-L',
+ 'gs://sometesturl/7871c8e24da15bad8b0be2c36edc9dc77e37727f')))
self.assertEqual(self.gsutil.history, expected_calls)
self.assertEqual(code, 0)
« no previous file with comments | « download_from_google_storage.py ('k') | tests/upload_to_google_storage_unittests.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698