Skip to content
This repository has been archived by the owner on Jan 20, 2022. It is now read-only.

Commit

Permalink
Merge pull request #233 from armenzg/origin/python_script
Browse files Browse the repository at this point in the history
Bug 1201668 - Allow running Firefox UI update tests through a python wrapper script. r=whimboo
(cherry picked from commit 310ff2d)
  • Loading branch information
armenzg authored and whimboo committed Sep 9, 2015
1 parent 5995adf commit 973aaa5
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 15 deletions.
5 changes: 2 additions & 3 deletions firefox_ui_harness/__init__.py
Expand Up @@ -2,9 +2,8 @@
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

from runtests import (cli,
cli_update,
)
from cli_update import cli_update
from runtests import cli

from testcases import (FirefoxTestCase,
UpdateTestCase,
Expand Down
15 changes: 15 additions & 0 deletions firefox_ui_harness/cli_update.py
@@ -0,0 +1,15 @@
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

from firefox_ui_harness.arguments import UpdateArguments
from firefox_ui_harness.runners import UpdateTestRunner
from firefox_ui_harness.runtests import cli


def cli_update():
cli(runner_class=UpdateTestRunner, parser_class=UpdateArguments)


if __name__ == '__main__':
cli_update()
13 changes: 2 additions & 11 deletions firefox_ui_harness/runtests.py
Expand Up @@ -10,13 +10,8 @@

from mozlog import structured

from firefox_ui_harness.arguments import (FirefoxUIArguments,
UpdateArguments,
)

from firefox_ui_harness.runners import (FirefoxUITestRunner,
UpdateTestRunner,
)
from firefox_ui_harness.arguments import FirefoxUIArguments
from firefox_ui_harness.runners import FirefoxUITestRunner


def startTestRunner(runner_class, options, tests):
Expand Down Expand Up @@ -78,9 +73,5 @@ def cli(runner_class=FirefoxUITestRunner, parser_class=FirefoxUIArguments):
sys.exit(1)


def cli_update():
cli(runner_class=UpdateTestRunner, parser_class=UpdateArguments)


if __name__ == '__main__':
sys.exit(cli())
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -39,5 +39,5 @@
entry_points="""
[console_scripts]
firefox-ui-tests = firefox_ui_harness:cli
firefox-ui-update = firefox_ui_harness:cli_update
firefox-ui-update = firefox_ui_harness.cli_update:cli_update
""")

0 comments on commit 973aaa5

Please sign in to comment.