Line | |
---|
1 | # Test the public API part of the university subpackage |
---|
2 | import unittest |
---|
3 | from waeup.sirp.university import * |
---|
4 | from waeup.sirp.testing import get_doctest_suite |
---|
5 | |
---|
6 | class UniversitySubpackageTests(unittest.TestCase): |
---|
7 | |
---|
8 | def test_public_api(self): |
---|
9 | names = globals().keys() |
---|
10 | self.assertTrue('Course' in names) |
---|
11 | self.assertTrue('CourseContainer' in names) |
---|
12 | self.assertTrue('Faculty' in names) |
---|
13 | self.assertTrue('FacultyContainer' in names) |
---|
14 | |
---|
15 | def test_suite(): |
---|
16 | # collect doctests for university subpackage |
---|
17 | suite = get_doctest_suite(['university/courserefs.txt',]) |
---|
18 | # add local unittests (actually only one) |
---|
19 | for testcase in [UniversitySubpackageTests,]: |
---|
20 | suite.addTests(unittest.TestLoader().loadTestsFromTestCase( |
---|
21 | testcase)) |
---|
22 | return suite |
---|
Note: See
TracBrowser for help on using the repository browser.