summaryrefslogtreecommitdiffstats
path: root/testing/mozbase/mozrunner/tests/test_states.py
blob: 1091438fe65aab40eb6a897057967372b7acfd3a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/usr/bin/env python

from __future__ import absolute_import

import mozunit
import pytest

from mozrunner import RunnerNotStartedError


def test_errors_before_start(runner):
    """Bug 965714: Not started errors before start() is called"""

    with pytest.raises(RunnerNotStartedError):
        runner.is_running()

    with pytest.raises(RunnerNotStartedError):
        runner.returncode

    with pytest.raises(RunnerNotStartedError):
        runner.wait()


if __name__ == "__main__":
    mozunit.main()