Macadamian/titanium_mobile — pull request #78 by dlifshitz-maca (2012-06-12 19:08:22+00:00)
Title: TIMOB-9279: BlackBerry: Add --blackberry-device and --blackberry-password to drillbit

Reviewers: Alex, Harut
Note: devicemanagement.py has been gutted in preparation for TIMOB-9378

[Issues Fixed]
TIMOB-9279: BlackBerry: Add --blackberry-device and --blackberry-password to drillbit

[Changes]
drillbit.py
- added usage

blackberry.js
- function BlackBerrySimulator
- store the blackberry args
- function createDeviceManagementProcess
- replace the unused args with the used ones
- functions isTestHarnessRunning, pushTestJS, launchTestHarness, killTestHarness
- use the builder process instead of devicemanagement

builder.py
- functions __init__, __name__
- add useLogFile param to direct output to log file or stdout based on the command
- function run
- move the package name to a reusable function getPackage
- added functions terminateApp, isAppRunning, printExitCode, getFile, putFile, appLog
- function __name__
- added usage, options, and handling for the new commands

devicemanagement.py
- use optparse instead of argparse
- move package-related commands to builder.py

[Tests]
Test 1: Run drillbit
1) Run scons to build the mobile sdk
2) Run the following command:
drillbit\drillbit.py --platforms=blackberry --blackberry-device=
3) Click "run tests"
4) Verify the test_harness app is built, deployed, and run
5) Verify the logs are printed
Note: The test will fail because some things aren't implemented