Merge lp:~tyler-baker/lava-dispatcher/refactor-nexus into lp:lava-dispatcher

Proposed by Tyler Baker
Status: Merged
Merged at revision: 569
Proposed branch: lp:~tyler-baker/lava-dispatcher/refactor-nexus
Merge into: lp:lava-dispatcher
Diff against target: 74 lines (+10/-10)
3 files modified
lava_dispatcher/config.py (+1/-1)
lava_dispatcher/default-config/lava-dispatcher/device-types/nexus.conf (+3/-3)
lava_dispatcher/device/fastboot.py (+6/-6)
To merge this branch: bzr merge lp:~tyler-baker/lava-dispatcher/refactor-nexus
Reviewer Review Type Date Requested Status
Tyler Baker Approve
Review via email: mp+156205@code.launchpad.net

Description of the change

* Rename nexus.py => fastboot.py
* nexus_working_directory => shared_working_directory
* client_type = nexus => fastboot
* Updated comments in nexus.conf
* The previous branch these changes were on diverged after the subprocess output fix was applied.

To post a comment you must log in.
Revision history for this message
Tyler Baker (tyler-baker) wrote :

Changes were approved by Antonio on 3/28/2013.

Revision history for this message
Tyler Baker (tyler-baker) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lava_dispatcher/config.py'
2--- lava_dispatcher/config.py 2013-02-18 06:00:28 +0000
3+++ lava_dispatcher/config.py 2013-03-29 18:33:21 +0000
4@@ -95,7 +95,7 @@
5
6 adb_command = schema.StringOption()
7 fastboot_command = schema.StringOption()
8- nexus_working_directory = schema.StringOption(default=None)
9+ shared_working_directory = schema.StringOption(default=None)
10
11 class OptionDescriptor(object):
12 def __init__(self, name):
13
14=== modified file 'lava_dispatcher/default-config/lava-dispatcher/device-types/nexus.conf'
15--- lava_dispatcher/default-config/lava-dispatcher/device-types/nexus.conf 2013-01-22 01:58:09 +0000
16+++ lava_dispatcher/default-config/lava-dispatcher/device-types/nexus.conf 2013-03-29 18:33:21 +0000
17@@ -25,19 +25,19 @@
18 # Working directory for temporary files. By default, the usual place for LAVA
19 # images will be used.
20 #
21-# This is useful when the lava dispatcher is controlling Nexus phones that are
22+# This is useful when the lava dispatcher is controlling the device under test which is
23 # physically plugged to other machines by setting adb_command to something like
24 # "ssh <phone-host> adb" and fastboot_command to something like "ssh
25 # <phone-host> fastboot". adb and fastboot always operate on local files, so
26 # you need your local files to also be seen as local files on the host where
27 # adb/fastboot are executed.
28 #
29-# In this case, you should set nexus_work_directory to a shared directory
30+# In this case, you should set shared_working_directory to a shared directory
31 # between the machine running the dispatcher and the machine where the phone is
32 # plugged. This shared directory must have the same path in both machines.
33 # For example, you can have your /var/tmp/lava mounted at /var/tmp/lava at
34 # <phone-host> (or the other way around).
35-nexus_working_directory =
36+shared_working_directory =
37
38 connection_command = %(adb_command)s shell
39
40
41=== renamed file 'lava_dispatcher/device/nexus.py' => 'lava_dispatcher/device/fastboot.py'
42--- lava_dispatcher/device/nexus.py 2013-03-26 01:02:10 +0000
43+++ lava_dispatcher/device/fastboot.py 2013-03-29 18:33:21 +0000
44@@ -94,10 +94,10 @@
45 self('boot %s' % image)
46
47
48-class NexusTarget(Target):
49+class FastbootTarget(Target):
50
51 def __init__(self, context, config):
52- super(NexusTarget, self).__init__(context, config)
53+ super(FastbootTarget, self).__init__(context, config)
54
55 if not config.hard_reset_command:
56 logging.warn(
57@@ -192,13 +192,13 @@
58
59 @property
60 def working_dir(self):
61- if (self.config.nexus_working_directory is None or
62- self.config.nexus_working_directory.strip() == ''):
63+ if (self.config.shared_working_directory is None or
64+ self.config.shared_working_directory.strip() == ''):
65 return self.scratch_dir
66
67 if self._working_dir is None:
68- self._working_dir = mkdtemp(self.config.nexus_working_directory)
69+ self._working_dir = mkdtemp(self.config.shared_working_directory)
70 return self._working_dir
71
72
73-target_class = NexusTarget
74+target_class = FastbootTarget

Subscribers

People subscribed via source and target branches