summaryrefslogtreecommitdiff
path: root/tests/test_runner_apps/failures/tests_failures.py
blob: dad875b8a61d2994fba60c8676e98b24103652ba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
from unittest import TestCase, expectedFailure


class FailureTestCase(TestCase):
    def test_sample(self):
        self.assertEqual(0, 1)


class ErrorTestCase(TestCase):
    def test_sample(self):
        raise Exception("test")


class ExpectedFailureTestCase(TestCase):
    @expectedFailure
    def test_sample(self):
        self.assertEqual(0, 1)


class UnexpectedSuccessTestCase(TestCase):
    @expectedFailure
    def test_sample(self):
        self.assertEqual(1, 1)