]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/blob - src/allmydata/test/trialtest.py
Merge pull request #232 from leif/2663.dont-test-attribute-order
[tahoe-lafs/tahoe-lafs.git] / src / allmydata / test / trialtest.py
1
2 # This is a dummy test suite that we can use to check that 'tahoe debug trial'
3 # is working properly. Since the module name does not start with 'test_', it
4 # will not be run by the main test suite.
5
6 from twisted.trial import unittest
7 from twisted.internet import defer
8
9
10 class Success(unittest.TestCase):
11     def test_succeed(self):
12         pass
13
14     def test_skip(self):
15         raise unittest.SkipTest('skip')
16
17     def test_todo(self):
18         self.fail('umm')
19     test_todo.todo = 'never mind'
20
21
22 class Failure(unittest.TestCase):
23     def test_fail(self):
24         self.fail('fail')
25
26     def test_error(self):
27         raise AssertionError('clang')
28
29     def test_deferred_error(self):
30         return defer.fail(AssertionError('screech'))