Merge lp://staging/~stylesen/lava-dispatcher/testdef-from-repo into lp://staging/lava-dispatcher
Proposed by
Senthil Kumaran S
Status: | Merged |
---|---|
Approved by: | Michael Hudson-Doyle |
Approved revision: | 450 |
Merged at revision: | 460 |
Proposed branch: | lp://staging/~stylesen/lava-dispatcher/testdef-from-repo |
Merge into: | lp://staging/lava-dispatcher |
Diff against target: |
191 lines (+115/-19) 1 file modified
lava_dispatcher/actions/lava_test_shell.py (+115/-19) |
To merge this branch: | bzr merge lp://staging/~stylesen/lava-dispatcher/testdef-from-repo |
Related bugs: | |
Related blueprints: |
Test Case Management Core
(Essential)
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Michael Hudson-Doyle (community) | Approve | ||
Review via email:
|
Description of the change
This branch implements the following features:
1) Adds ability to pull a bzr/git repo that includes the test def.
2) Adds ability to pull a specific revision of the repo.
To post a comment you must log in.
Senthil Kumaran S <email address hidden> writes:
> Senthil Kumaran S has proposed merging lp:~stylesen/lava-dispatcher/testdef-from-repo into lp:lava-dispatcher. /code.launchpad .net/~stylesen/ lava-dispatcher /testdef- from-repo/ +merge/ 134835 /code.launchpad .net/~stylesen/ lava-dispatcher /testdef- from-repo/ +merge/ 134835
>
> Requested reviews:
> Linaro Validation Team (linaro-validation)
>
> For more details, see:
> https:/
>
> This branch implements the following features:
>
> 1) Adds ability to pull a bzr/git repo that includes the test def.
> 2) Adds ability to pull a specific revision of the repo.
>
> --
> https:/
> You are subscribed to branch lp:lava-dispatcher.
Hi Senthil,
This branch looks really pretty great (I have a test branch based on quibbles, but I think
this and some other branches that I'm going to be trying to implement
audio capture with it today). Thanks so much for taking Andy's and my
suggestions on board. I have a few suggestions/
this will be ready for landing very soon.
> === modified file 'lava_dispatche r/actions/ lava_test_ shell.py' /actions/ lava_test_ shell.py 2012-11-08 14:08:30 +0000 /actions/ lava_test_ shell.py 2012-11-19 06:43:11 +0000
> --- lava_dispatcher
> +++ lava_dispatcher
> @@ -22,6 +22,8 @@
>
> import json
> import yaml
> +import glob
> +import time
> import logging
> import os
> import pexpect
> @@ -100,17 +102,20 @@
> parameters_schema = {
> 'type': 'object',
> 'properties': {
> - 'testdef_urls': {'type': 'array', 'items': {'type': 'string'}},
> + 'testdef_urls': {'type': 'array', 'items': {'type': 'string'},
> + 'optional': True},
> + 'testdef_repos': {'type': 'array', 'items': {'type': 'object'},
> + 'optional': True},
I think it's possible to be more specific here isn't it? You could
specify the properties the objects in the testdef_repos array is allowed
to have. But maybe let's not worry about this for now.
> 'timeout': {'type': 'integer', 'optional': True}, erties' : False, target_ device target( target) _target( target, testdef_urls) _target( target, testdef_urls, testdef_repos) results( target) definition( self, testdef_url, tmpdir): image(testdef_ url, self.context, tmpdir) info('loading test definition') definition_ from_url( self, d, ldir, testdef_urls, tmpdir):
> },
> 'additionalProp
> }
>
> - def run(self, testdef_urls, timeout=-1):
> + def run(self, testdef_urls=None, testdef_repos=None, timeout=-1):
> target = self.client.
> self._assert_
>
> - self._configure
> + self._configure
>
> with target.runner() as runner:
> patterns = [
> @@ -128,11 +133,86 @@
>
> self._bundle_
>
> - def _get_test_
> - testdef_file = download_
> - with open(testdef_file, 'r') as f:
> - logging.
> - return yaml.load(f)
> + def _get_test_
> + tdirs = []
> + for url in testdef_urls:
> + testdef_file = download_image(url, self.context, tmpdir)
> + with open(testdef_file, 'r') as f:
> + logging.info(...