autopilot ignores class-level conditional skip() decorator
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Autopilot |
Confirmed
|
Medium
|
Unassigned |
Bug Description
The webbrowser_app test suite has a few tests that are conditionally skipped depending on the platform, such as:
@unittest.
def test_swipe_
…
This works well for skipping one specific test method, but it doesn’t seem to work for skipping an entire TestCase. We’re adding support for keyboard shortcuts in the browser, which obviously makes sense only on platforms with a physical keyboard, so we would like to skip the entire test case when not on desktop, but it seems the decorator is ignored by autopilot, and it tries to run all the tests:
@unittest.
class TestKeyboard(
…
This should probably work, but have you tried using testtools.skipIf? This seems to work for me