Commit Graph

12 Commits

Author SHA1 Message Date
William Lachance
c5f092dab4 Bug 795496 - Make mozdevice raise exceptions on error;r=ahal,jmaher
It turns out that relying on the user to check return codes for every
command was non-intuitive and resulted in many hard to trace bugs.
Now most functinos just return "None", and raise a DMError when there's an
exception. The exception to this are functions like dirExists, which now return
booleans, and throw exceptions on error. This is a fairly major refactor,
and also involved the following internal changes:

* Removed FileError and AgentError exceptions, replaced with DMError
  (having to manage three different types of exceptions was confusing,
  all the more so when we're raising them)
* Docstrings updated to remove references to return values where no
  longer relevant
* pushFile no longer will create a directory to accomodate the file
  if it doesn't exist (this makes it consistent with devicemanagerADB)
* dmSUT we validate the file, but assume that we get something back
  from the agent, instead of falling back to manual validation in the
  case that we didn't
* isDir and dirExists had the same intention, but different
  implementations for dmSUT. Replaced the dmSUT impl of getDirectory
  with that of isDir's (which was much simpler). Removed
  isDir from devicemanager.py, since it wasn't used externally
* killProcess modified to check for process existence before running
  (since the actual internal kill command will throw an exception
  if the process doesn't exist)

In addition to all this, more unit tests have been added to test these
changes for devicemanagerSUT.
2012-10-04 11:28:07 -04:00
David Chan
e537e59ad4 Bug 797177 - Unbreak b2g mochitests, r=ahal 2012-10-02 15:43:19 -07:00
Jonathan Griffin
bb23dbc168 Bug 795100 - Add a --gecko-path argument to the B2G mochitest testrunner, r=ahal, DONTBUILD(NPOTB) 2012-09-28 10:04:03 -07:00
David Clarke
34c826661c Bug 790546 - Add sdcard option to emulator, r=jgriffin, DONTBUILD because NPOTB 2012-09-17 18:44:07 -07:00
David Clarke
b21f658491 Bug 780031 - Mochitest on b2g reliability improvements, r=jgriffin, DONTBUILD because NPOTB 2012-08-08 17:29:26 -07:00
Jonathan Griffin
eceb527930 Bug 777871 - Get mochitests running OOP in B2G, r=jlebar, DONTBUILD because NPOTB 2012-08-02 13:30:25 -07:00
Jonathan Griffin
23c5b2dbe8 Bug 774951 - Allow extensions to be excluded when running mochitest, r=jmaher 2012-07-19 10:31:51 -07:00
Jonathan Griffin
bb189eab03 Bug 772687 - Add ability to specify deviceRoot when instantiating DeviceManager, r=jmaher 2012-07-11 11:49:30 -07:00
Andrew Halberstadt
25b3d30c16 Bug 765015 - Don't stop server if it doesn't exist, r=jgriffin, DONTBUILD because NPOTB 2012-06-15 14:13:04 -07:00
Jonathan Griffin
a51a6dc5e0 Bug 759887 - Add no-window support to runtestsb2g.py, a=test-only, DONTBUILD because NPOTB 2012-06-08 14:09:14 -07:00
Jonathan Griffin
d3e3ecc476 Bug 759885 - Add support for running mochitest-plain on B2G emulators, r=jmaher, DONTBUILD because NPOTB 2012-06-05 15:17:26 -07:00
Jonathan Griffin
86a2c2032d Bug 749011 - Add support for running mochitest-plain on B2G, r=jmaher
--HG--
extra : rebase_source : 4c260e11c51c5015d2ded66f4b8cfc94a9969298
2012-04-27 11:44:59 -07:00