Last Comment Bug 742513 - 'make marionette' test command needed for gaia
: 'make marionette' test command needed for gaia
Status: RESOLVED FIXED
:
Product: Testing
Classification: Components
Component: Marionette (show other bugs)
: Trunk
: x86 All
: -- normal (vote)
: mozilla14
Assigned To: Malini Das [:mdas] - Away, not checking bugmail
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-04 13:26 PDT by Malini Das [:mdas] - Away, not checking bugmail
Modified: 2012-04-05 11:15 PDT (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
marionette client changes (8.69 KB, patch)
2012-04-04 13:32 PDT, Malini Das [:mdas] - Away, not checking bugmail
jgriffin: review+
Details | Diff | Review
Updated patch (8.70 KB, patch)
2012-04-04 14:26 PDT, Malini Das [:mdas] - Away, not checking bugmail
malini: review+
Details | Diff | Review

Description Malini Das [:mdas] - Away, not checking bugmail 2012-04-04 13:26:15 PDT
We need to create a `make marionette` command for use with the gaia/ repository to make testing easier. This will require code check-in on m-c and in the gaia/ repo.

m-c code will see changes in the marionette client, so it can execute a b2g desktop binary.

gaia code changes will be the actual make command.
Comment 1 Malini Das [:mdas] - Away, not checking bugmail 2012-04-04 13:32:56 PDT
Created attachment 612318 [details] [diff] [review]
marionette client changes

This patch allows the marionette client to start a b2g desktop instance from an executable (and passes it the needed profile information), as used by the gaia team.

This patch creates a class that handles the running b2g instance and modifies runtests.py and marionette.py accordingly.
Comment 2 Jonathan Griffin (:jgriffin) 2012-04-04 14:02:05 PDT
Comment on attachment 612318 [details] [diff] [review]
marionette client changes

Review of attachment 612318 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good with a few minor changes:

::: testing/marionette/client/marionette/b2ginstance.py
@@ +13,5 @@
> +        self.b2gbin = b2gbin
> +        self.proc = None
> +
> +    def start(self):
> +        args = [self.b2gbin, '-profile', os.path.join(os.getenv('GAIA'), "profile")]

We should probably verify that os.getenv('GAIA') points to something real, and throw if not.

@@ +14,5 @@
> +        self.proc = None
> +
> +    def start(self):
> +        args = [self.b2gbin, '-profile', os.path.join(os.getenv('GAIA'), "profile")]
> +        args = ["/Users/mdas/Code/other-moz/mozilla/obj-b2g-desktop/dist/bin/b2g", '-profile', os.path.join(os.getenv('GAIA'), "profile")]

Looks like some debugging code was left in here.

::: testing/marionette/client/marionette/runtests.py
@@ +184,5 @@
>                                              connectToRunningEmulator=True,
>                                              homedir=self.homedir,
>                                              baseurl=self.baseurl)
> +            if self.b2gbin:
> +                self.marionette = Marionette(host=host, port=int(port), b2gbin=self.b2gbin)

We should include the baseurl parameter with this instantiation of Marionette; the 'baseurl' is the root address of Marionette's webserver.
Comment 3 Malini Das [:mdas] - Away, not checking bugmail 2012-04-04 14:26:28 PDT
Created attachment 612335 [details] [diff] [review]
Updated patch

Fixed the patch and tested it.
Comment 4 Jonathan Griffin (:jgriffin) 2012-04-04 15:58:47 PDT
http://hg.mozilla.org/integration/mozilla-inbound/rev/fdac8905b6de
Comment 5 :Ehsan Akhgari (busy, don't ask for review please) 2012-04-05 11:15:10 PDT
http://hg.mozilla.org/mozilla-central/rev/fdac8905b6de

Note You need to log in before you can comment on or make changes to this bug.