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

Side by Side Diff: third_party/gsutil/gslib/tests/test_perfdiag.py

Issue 12317103: Added gsutil to depot tools (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: added readme Created 7 years, 9 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 unified diff | Download patch
OLDNEW
(Empty)
1 # Copyright 2013 Google Inc. All Rights Reserved.
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 # http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 import gslib.tests.testcase as testcase
16 from gslib.tests.util import ObjectToURI as suri
17
18
19 class TestPerfDiag(testcase.GsUtilIntegrationTestCase):
20 """Integration tests for perfdiag command."""
21
22 def test_latency(self):
23 bucket_uri = self.CreateBucket()
24 self.RunGsUtil(['perfdiag', '-n', '1', '-t', 'lat', suri(bucket_uri)])
25
26 def test_write_throughput(self):
27 bucket_uri = self.CreateBucket()
28 self.RunGsUtil(['perfdiag', '-n', '1', '-s', '1024', '-t', 'wthru',
29 suri(bucket_uri)])
30
31 def test_read_throughput(self):
32 bucket_uri = self.CreateBucket()
33 self.RunGsUtil(['perfdiag', '-n', '1', '-s', '1024', '-t', 'rthru',
34 suri(bucket_uri)])
35
36 def test_input_output(self):
37 outpath = self.CreateTempFile()
38 bucket_uri = self.CreateBucket()
39 self.RunGsUtil(['perfdiag', '-o', outpath, '-n', '1', '-t', 'lat',
40 suri(bucket_uri)])
41 self.RunGsUtil(['perfdiag', '-i', outpath])
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698