Home
last modified time | relevance | path

Searched refs:suri (Results 1 – 25 of 33) sorted by relevance

12

/external/chromium-trace/catapult/third_party/gsutil/gslib/tests/
Dtest_naming.py44 from gslib.tests.util import ObjectToURI as suri unknown
85 self.assertEqual(suri(src_dir),
87 StorageUrlFromString(suri(subdir))))
94 self.RunCommand('cp', [src_file, suri(dst_bucket_uri)])
96 suri(dst_bucket_uri, '**')).IterAll(expand_top_level_buckets=True))
106 self.RunCommand('cp', [src_file0, src_file1, suri(dst_bucket_uri)])
108 suri(dst_bucket_uri, '**')).IterAll(expand_top_level_buckets=True))
110 suri(dst_bucket_uri, 'f0'),
111 suri(dst_bucket_uri, 'f1'),
128 self.RunCommand('cp', [src_file, suri(dst_bucket_uri, 'subdir/a')])
[all …]
Dtest_du.py21 from gslib.tests.util import ObjectToURI as suri unknown
48 stdout = self.RunGsUtil(['du', suri(obj_uri)], return_stdout=True)
49 self.assertEqual(stdout, '%-10s %s\n' % (3, suri(obj_uri)))
58 stdout = self.RunGsUtil(['du', suri(bucket_uri)], return_stdout=True)
59 self.assertEqual(stdout, '%-10s %s\n' % (3, suri(obj_uri)))
69 stdout = self.RunGsUtil(['du', suri(bucket_uri)], return_stdout=True)
71 '%-10s %s' % (5, suri(obj_uris[0])),
72 '%-10s %s' % (4, suri(obj_uris[1])),
73 '%-10s %s' % (5, suri(obj_uris[2])),
74 '%-10s %s' % (4, suri(obj_uris[3])),
[all …]
Dtest_parallel_cp.py38 from gslib.tests.util import ObjectToURI as suri unknown
51 self.RunGsUtil(['cp', src_file, suri(dst_bucket_uri)])
54 self.assertEqual(suri(dst_bucket_uri, 'f0'), lines[0])
62 self.RunGsUtil(['cp', src_file0, src_file1, suri(dst_bucket_uri)])
65 self.assertEqual(suri(dst_bucket_uri, 'f0'), lines[0])
66 self.assertEqual(suri(dst_bucket_uri, 'f1'), lines[1])
81 self.RunGsUtil(['cp', src_file, suri(dst_bucket_uri, 'subdir/a')])
82 self.RunGsUtil(['cp', src_file, suri(dst_bucket_uri, 'subdir')])
85 self.assertEqual(suri(dst_bucket_uri, 'subdir/a'), lines[0])
86 self.assertEqual(suri(dst_bucket_uri, 'subdir/obj'), lines[1])
[all …]
Dtest_rm.py25 from gslib.tests.util import ObjectToURI as suri unknown
113 stderr = self.RunGsUtil(['-m', 'rm', '-a', suri(key_uri)],
119 self.assertIn('Removing %s#%s...' % (suri(key_uri), g1), stderr)
120 self.assertIn('Removing %s#%s...' % (suri(key_uri), g2), stderr)
134 ['-m', 'rm', '-a', suri(key_uri)],
135 objects_to_remove=['%s#%s' % (suri(key_uri), g1),
136 '%s#%s' % (suri(key_uri), g2)])
141 stderr = self.RunGsUtil(['rm', '-a', '%s' % suri(bucket_uri, 'foo')],
162 ['rm', '-r', suri(bucket_uri)],
163 objects_to_remove=['%s#%s' % (suri(k1_uri), k1g1),
[all …]
Dtest_rsync.py23 from gslib.tests.util import ObjectToURI as suri unknown
82 return self.RunGsUtil(['ls', suri(bucket_url_string, '**')],
92 self.RunGsUtil(['rsync', suri(obj1), suri(bucket_uri)], expected_status=1)
94 self.RunGsUtil(['rsync', suri(bucket_uri), suri(obj1)], expected_status=1)
96 self.RunGsUtil(['rsync', suri(bucket_uri), self.nonexistent_bucket_name],
99 self.RunGsUtil(['rsync', suri(obj1), tmpdir], expected_status=1)
101 self.RunGsUtil(['rsync', tmpdir, suri(obj1)], expected_status=1)
103 self.RunGsUtil(['rsync', tmpdir, suri(obj1), self.nonexistent_bucket_name],
139 self.RunGsUtil(['rsync', suri(bucket1_uri), suri(bucket2_uri)])
140 listing1 = _TailSet(suri(bucket1_uri), self._FlatListBucket(bucket1_uri))
[all …]
Dtest_defacl.py24 from gslib.tests.util import ObjectToURI as suri unknown
51 [suri(bucket)], return_stdout=True)
55 ['-g', self.GROUP_TEST_ADDRESS+':FC', suri(bucket)])
57 [suri(bucket)], return_stdout=True)
61 ['-g', self.GROUP_TEST_ADDRESS+':READ', suri(bucket)])
63 [suri(bucket)], return_stdout=True)
68 suri(bucket)],
78 self.RunGsUtil(self._defacl_set_prefix + ['private', suri(bucket)])
80 [suri(bucket)], return_stdout=True)
87 ['-g', self.GROUP_TEST_ADDRESS+':READ', suri(bucket)])
[all …]
Dtest_ls.py28 from gslib.tests.util import ObjectToURI as suri unknown
50 stdout = self.RunGsUtil(['ls', '-b', suri(bucket_uri)],
52 self.assertEqual('%s/\n' % suri(bucket_uri), stdout)
61 stdout = self.RunGsUtil(['ls', '-Lb', suri(bucket_uri)],
63 self.assertIn(suri(bucket_uri), stdout)
73 stdout = self.RunGsUtil(['ls', '-lb', suri(bucket_uri)],
75 self.assertIn(suri(bucket_uri), stdout)
90 common_prefix = posixpath.commonprefix([suri(bucket1_uri),
91 suri(bucket2_uri)])
101 expected = set([suri(bucket1_uri) + '/', suri(bucket2_uri) + '/'])
[all …]
Dtest_lifecycle.py26 from gslib.tests.util import ObjectToURI as suri unknown
75 stdout = self.RunGsUtil(['lifecycle', 'get', suri(bucket_uri)],
82 self.RunGsUtil(['lifecycle', 'set', fpath, suri(bucket_uri)])
83 stdout = self.RunGsUtil(['lifecycle', 'get', suri(bucket_uri)],
90 self.RunGsUtil(['lifecycle', 'set', fpath, suri(bucket_uri)])
91 stdout = self.RunGsUtil(['lifecycle', 'get', suri(bucket_uri)],
98 self.RunGsUtil(['lifecycle', 'set', fpath, suri(bucket_uri)])
99 stdout = self.RunGsUtil(['lifecycle', 'get', suri(bucket_uri)],
106 self.RunGsUtil(['lifecycle', 'set', fpath, suri(bucket_uri)])
107 stdout = self.RunGsUtil(['lifecycle', 'get', suri(bucket_uri)],
[all …]
Dtest_stat.py21 from gslib.tests.util import ObjectToURI as suri unknown
30 stdout = self.RunGsUtil(['stat', suri(object_uri)], return_stdout=True)
59 stdout = self.RunGsUtil(['-q', 'stat', suri(object_uri)],
62 stdout = self.RunGsUtil(['-q', 'stat', suri(object_uri, 'junk')],
76 ['stat', suri(bucket_uri, 'missing'), suri(bucket_uri, 'notmissing')],
78 self.assertIn('No URLs matched %s' % suri(bucket_uri, 'missing'), stderr)
79 self.assertIn('%s:' % suri(bucket_uri, 'notmissing'), stdout)
86 ['stat', suri(bucket_uri, 'missin*'), suri(bucket_uri, 'notmissin*')],
88 self.assertIn('No URLs matched %s' % suri(bucket_uri, 'missin*'), stderr)
89 self.assertIn('%s:' % suri(bucket_uri, 'notmissing'), stdout)
[all …]
Dtest_cors.py25 from gslib.tests.util import ObjectToURI as suri unknown
93 stdout = self.RunGsUtil(self._get_cmd_prefix + [suri(bucket_uri)],
100 self.RunGsUtil(self._set_cmd_prefix + [fpath, suri(bucket_uri)])
101 stdout = self.RunGsUtil(self._get_cmd_prefix + [suri(bucket_uri)],
108 self.RunGsUtil(self._set_cmd_prefix + [fpath, suri(bucket_uri)])
109 stdout = self.RunGsUtil(self._get_cmd_prefix + [suri(bucket_uri)],
116 self.RunGsUtil(self._set_cmd_prefix + [fpath, suri(bucket_uri)])
117 stdout = self.RunGsUtil(self._get_cmd_prefix + [suri(bucket_uri)],
124 stderr = self.RunGsUtil(self._set_cmd_prefix + [fpath, suri(bucket_uri)],
131 stderr = self.RunGsUtil(self._set_cmd_prefix + [fpath, suri(bucket_uri)],
[all …]
Dtest_bucketconfig.py20 from gslib.tests.util import ObjectToURI as suri unknown
61 self.RunGsUtil(self._set_cors_command + [cors_path, suri(bucket_uri)])
62 cors_out = self.RunGsUtil(self._get_cors_command + [suri(bucket_uri)],
67 suri(bucket_uri)])
68 cors_out = self.RunGsUtil(self._get_cors_command + [suri(bucket_uri)],
71 [suri(bucket_uri)], return_stdout=True)
76 self._set_acl_command + ['authenticated-read', suri(bucket_uri)])
78 cors_out = self.RunGsUtil(self._get_cors_command + [suri(bucket_uri)],
81 [suri(bucket_uri)], return_stdout=True)
82 acl_out = self.RunGsUtil(self._get_acl_command + [suri(bucket_uri)],
[all …]
Dtest_cat.py20 from gslib.tests.util import ObjectToURI as suri unknown
31 stderr = self.RunGsUtil(['cat', '-r -', suri(key_uri)],
34 stderr = self.RunGsUtil(['cat', '-r a-b', suri(key_uri)],
37 stderr = self.RunGsUtil(['cat', '-r 1-2-3', suri(key_uri)],
40 stderr = self.RunGsUtil(['cat', '-r 1.7-3', suri(key_uri)],
45 stdout = self.RunGsUtil(['cat', '-r 1-3', suri(key_uri)],
48 stdout = self.RunGsUtil(['cat', '-r 8-', suri(key_uri)],
51 stdout = self.RunGsUtil(['cat', '-r 0-0', suri(key_uri)],
54 stdout = self.RunGsUtil(['cat', '-r -3', suri(key_uri)],
65 stdout = self.RunGsUtil(['cat', suri(uri1)], return_stdout=True)
[all …]
Dtest_versioning.py20 from gslib.tests.util import ObjectToURI as suri unknown
33 self._get_ver_cmd + [suri(bucket_uri)], return_stdout=True)
34 self.assertEqual(stdout.strip(), '%s: Suspended' % suri(bucket_uri))
38 self.RunGsUtil(self._set_ver_cmd + ['on', suri(bucket_uri)])
44 self._get_ver_cmd + [suri(bucket_uri)], return_stdout=True)
45 self.assertEqual(stdout.strip(), '%s: Enabled' % suri(bucket_uri))
50 self.RunGsUtil(self._set_ver_cmd + ['on', suri(bucket_uri)])
56 self._get_ver_cmd + [suri(bucket_uri)], return_stdout=True)
57 self.assertEqual(stdout.strip(), '%s: Enabled' % suri(bucket_uri))
60 self.RunGsUtil(self._set_ver_cmd + ['off', suri(bucket_uri)])
[all …]
Dtest_cp.py55 from gslib.tests.util import ObjectToURI as suri unknown
268 stderr = self.RunGsUtil(['cp', '-n', fpath, suri(key_uri)],
270 self.assertIn('Skipping existing item: %s' % suri(key_uri), stderr)
272 stderr = self.RunGsUtil(['cp', '-n', suri(key_uri), fpath],
275 self.assertIn('Skipping existing item: %s' % suri(f), stderr)
290 stderr = self.RunGsUtil(['cp', suri(key_uri), suri(bucket2_uri)],
295 stderr = self.RunGsUtil(['cp', '-n', suri(key_uri), suri(bucket2_uri)],
298 suri(bucket2_uri, key_uri.object_name), stderr)
303 stderr = self.RunGsUtil(['cp', '-', '%s' % suri(bucket_uri, 'foo')],
311 stderr = self.RunGsUtil(['cp', '-', '-', suri(bucket_uri)],
[all …]
Dtest_acl.py29 from gslib.tests.util import ObjectToURI as suri unknown
60 obj_uri = suri(self.CreateObject(contents='foo'))
68 bucket_uri = suri(self.CreateBucket())
76 obj_uri = suri(self.CreateObject(contents='foo'))
85 bucket_uri = suri(self.CreateBucket())
94 obj_uri = suri(self.CreateObject(contents='foo'))
110 obj_uri = suri(self.CreateObject(contents='foo'))
121 bucket_uri = suri(self.CreateBucket())
137 obj_uri = suri(self.CreateObject(contents='foo'))
149 obj_uri1 = suri(self.CreateObject(bucket_uri=bucket_uri, contents='foo'))
[all …]
Dtest_wildcard_iterator.py32 from gslib.tests.util import ObjectToURI as suri unknown
47 self.base_uri_str = suri(self.base_bucket_uri)
57 self.test_bucket0_obj_uri_strs.add(suri(obj_uri))
65 self.test_bucket1_obj_uri_strs.add(suri(obj_uri))
130 exp_obj_uri_strs = set([suri(self.test_bucket0_uri, x)
188 suri(self.test_bucket1_uri) + self.test_bucket1_uri.delim])
197 suri(self.test_bucket0_uri) + self.test_bucket0_uri.delim,
198 suri(self.test_bucket1_uri) + self.test_bucket1_uri.delim])
263 suri(self.test_dir, 'abcd'),
264 suri(self.test_dir, 'abdd'),
[all …]
Dtest_setmeta.py22 from gslib.tests.util import ObjectToURI as suri unknown
32 objuri = suri(self.CreateObject(contents='foo'))
47 objuri = suri(self.CreateObject(contents='foo'))
70 '-h', 'Content-Type:%s' % ct, suri(object_uri)], expected_status=1,
81 '-h', 'Content-Type:%s' % ct, suri(object_uri)])
82 stdout = self.RunGsUtil(['ls', '-L', suri(object_uri)], return_stdout=True)
94 '-h', 'Content-Type:%s' % ct, suri(object_uri)], expected_status=1,
100 '-h', 'Content-Type:%s' % ct, suri(object_uri)])
101 stdout = self.RunGsUtil(['ls', '-L', suri(object_uri)], return_stdout=True)
122 suri(bucket_uri)])
[all …]
Dtest_mv.py22 from gslib.tests.util import ObjectToURI as suri unknown
40 cmd = (['-m', 'mv'] + objs + [suri(bucket2_uri)])
61 objs = [suri(bucket2_uri.clone_replace_key(key))
63 cmd = (['-m', 'mv'] + objs + [suri(bucket1_uri)])
77 self.RunGsUtil(['mv', dir_to_move, suri(bucket_uri)])
87 self.RunGsUtil(['mv', '-I', suri(bucket_uri)],
93 stdout = self.RunGsUtil(['ls', suri(bucket_uri)], return_stdout=True)
104 stderr = self.RunGsUtil(['mv', '-n', fpath1, suri(object_uri)],
107 self.assertIn('Skipping existing item: %s' % suri(object_uri), stderr)
108 self.assertNotIn('Removing %s' % suri(fpath1), stderr)
[all …]
Dtest_web.py22 from gslib.tests.util import ObjectToURI as suri unknown
40 self._set_web_cmd + ['-m', 'main', '-e', '404', suri(bucket_uri)])
42 self._get_web_cmd + [suri(bucket_uri)], return_stdout=True)
47 self.RunGsUtil(self._set_web_cmd + ['-m', 'main', suri(bucket_uri)])
49 self._get_web_cmd + [suri(bucket_uri)], return_stdout=True)
54 self.RunGsUtil(self._set_web_cmd + ['-e', '404', suri(bucket_uri)])
56 self._get_web_cmd + [suri(bucket_uri)], return_stdout=True)
61 self.RunGsUtil(self._set_web_cmd + [suri(bucket_uri)])
63 self._get_web_cmd + [suri(bucket_uri)], return_stdout=True)
Dtest_compose.py23 from gslib.tests.util import ObjectToURI as suri unknown
107 self.RunGsUtil(['-h', gen_match_header, 'compose', suri(k1_uri),
108 suri(k2_uri), suri(k1_uri)])
111 stderr = self.RunGsUtil(['-h', gen_match_header, 'compose', suri(k1_uri),
112 suri(k2_uri), suri(k1_uri)],
122 stderr = self.RunGsUtil(['compose', suri(object_uri),
123 suri(bucket_uri, 'nonexistent-obj'),
124 suri(bucket_uri, 'valid-destination')],
Dtest_rb.py20 from gslib.tests.util import ObjectToURI as suri unknown
28 self.RunGsUtil(['rb', suri(bucket_uri)])
36 stderr = self.RunGsUtil(['rb', suri(bucket_uri)], expected_status=1,
42 stderr = self.RunGsUtil(['rb', suri(bucket_uri)], expected_status=1,
56 suri(bucket_uri)], return_stderr=True, expected_status=1)
61 ['ls', '-Lb', suri(bucket_uri)], return_stderr=True, expected_status=1)
Dtest_notification.py25 from gslib.tests.util import ObjectToURI as suri unknown
44 'notification', 'watchbucket', NOTIFICATION_URL, suri(bucket_uri)])
50 NOTIFICATION_URL, suri(bucket_uri)], return_stderr=True)
60 ['notification', 'watchbucket', NOTIFICATION_URL, suri(bucket_uri)],
Dtest_Doption.py25 from gslib.tests.util import ObjectToURI as suri unknown
43 ['-D', 'cp', fpath, suri(bucket_uri)], return_stderr=True)
44 print 'command line:' + ' '.join(['-D', 'cp', fpath, suri(bucket_uri)])
57 ['-D', 'cp', fpath, suri(bucket_uri)], return_stderr=True)
67 ['-D', 'cat', suri(key_uri)], return_stdout=True, return_stderr=True)
Dtest_perfdiag.py25 from gslib.tests.util import ObjectToURI as suri unknown
56 cmd = ['perfdiag', '-n', '1', '-t', 'lat', suri(bucket_uri)]
71 cmd += [suri(bucket_uri)]
134 suri(bucket_uri)])
152 ['perfdiag', '-n', '1', '-t', 'list', suri(bucket_uri)],
Dtest_mb.py21 from gslib.tests.util import ObjectToURI as suri unknown
30 stderr = self.RunGsUtil(['mb', suri(bucket_uri)], expected_status=1,

12