BaseMarionetteOptions.verify_usage() should use self.error() instead of print and sys.exit(1)

NEW
Unassigned

Status

Testing
Marionette
3 years ago
3 years ago

People

(Reporter: whimboo, Unassigned)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

The option parser has a method called `error()` which can be used to print out errors to the console and exit the application.

That means instead of:

> if not tests:
>     print 'must specify one or more test files, manifests, or directories'
>     sys.exit(1)

we can use:

> if not tests:
>     self.error('must specify one or more test files, manifests, or directories')

There are a couple of those instances left, which would need a fix.
You need to log in before you can comment on or make changes to this bug.