mirror of
https://github.com/ceph/ceph
synced 2025-01-29 14:34:40 +00:00
cram: support fetching from sha1 branch, tag, commit hash
Signed-off-by: Venky Shankar <vshankar@redhat.com>
This commit is contained in:
parent
79c2db9bea
commit
d2f0d74598
@ -2,4 +2,4 @@ tasks:
|
||||
- cram:
|
||||
clients:
|
||||
client.0:
|
||||
- http://git.ceph.com/?p=ceph.git;a=blob_plain;f=src/test/cli-integration/rbd/unmap.t
|
||||
- http://git.ceph.com/?p=ceph.git;a=blob_plain;hb={branch};f=src/test/cli-integration/rbd/unmap.t
|
||||
|
@ -7,4 +7,4 @@ tasks:
|
||||
- cram:
|
||||
clients:
|
||||
client.0:
|
||||
- http://git.ceph.com/?p=ceph.git;a=blob_plain;f=src/test/cli-integration/rbd/formatted-output.t
|
||||
- http://git.ceph.com/?p=ceph.git;a=blob_plain;hb={branch};f=src/test/cli-integration/rbd/formatted-output.t
|
||||
|
@ -29,6 +29,7 @@ def task(ctx, config):
|
||||
- http://ceph.com/qa/test.t
|
||||
- http://ceph.com/qa/test2.t]
|
||||
client.1: [http://ceph.com/qa/test.t]
|
||||
branch: foo
|
||||
|
||||
You can also run a list of cram tests on all clients::
|
||||
|
||||
@ -49,6 +50,17 @@ def task(ctx, config):
|
||||
config['clients'])
|
||||
testdir = teuthology.get_testdir(ctx)
|
||||
|
||||
overrides = ctx.config.get('overrides', {})
|
||||
teuthology.deep_merge(config, overrides.get('workunit', {}))
|
||||
|
||||
refspec = config.get('branch')
|
||||
if refspec is None:
|
||||
refspec = config.get('tag')
|
||||
if refspec is None:
|
||||
refspec = config.get('sha1')
|
||||
if refspec is None:
|
||||
refspec = 'HEAD'
|
||||
|
||||
try:
|
||||
for client, tests in clients.iteritems():
|
||||
(remote,) = ctx.cluster.only(client).remotes.iterkeys()
|
||||
@ -68,7 +80,7 @@ def task(ctx, config):
|
||||
assert test.endswith('.t'), 'tests must end in .t'
|
||||
remote.run(
|
||||
args=[
|
||||
'wget', '-nc', '-nv', '-P', client_dir, '--', test,
|
||||
'wget', '-nc', '-nv', '-P', client_dir, '--', test.format(branch=refspec),
|
||||
],
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user