diff options
author | Rafael G. Martins <rafael@rafaelmartins.eng.br> | 2010-05-23 02:04:04 -0300 |
---|---|---|
committer | Rafael G. Martins <rafael@rafaelmartins.eng.br> | 2010-05-23 02:04:04 -0300 |
commit | 241a0a3609bdcf86e2e2ff49d9c37483ca8615ed (patch) | |
tree | 6c3d89eca9a916e38988cc37e93abc8feacfe917 /tests | |
parent | removed re_atom from the __all__ list of g_octave/description.py (diff) | |
download | g-octave-241a0a3609bdcf86e2e2ff49d9c37483ca8615ed.tar.gz g-octave-241a0a3609bdcf86e2e2ff49d9c37483ca8615ed.tar.bz2 g-octave-241a0a3609bdcf86e2e2ff49d9c37483ca8615ed.zip |
finished description.py tests and fixed small errors.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_description.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/test_description.py b/tests/test_description.py index 112f63f..ae32128 100644 --- a/tests/test_description.py +++ b/tests/test_description.py @@ -170,10 +170,30 @@ class TestDescription(unittest.TestCase): pkgtpl ) + def test_attributes(self): + self.assertEqual(self.desc.name, 'package name') + self.assertEqual(self.desc.version, '0.0.1') + self.assertEqual(self.desc.date, '2009-01-01') + self.assertEqual(self.desc.author, 'Author Name') + self.assertEqual(self.desc.maintainer, 'Maintainer Name') + self.assertEqual(self.desc.title, 'Package Title') + self.assertEqual(self.desc.description, 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.') + self.assertEqual(self.desc.categories, 'Category1,Category2, Category3') + self.assertEqual(self.desc.url, 'http://example.org') + + # the requirements can't be tested :( + self.assertEqual(self.desc.systemrequirements, []) + self.assertEqual(self.desc.buildrequires, []) + + self.assertEqual(self.desc.depends, ['>=sci-mathematics/octave-3.0.0']) + self.assertEqual(self.desc.autoload, 'NO') + self.assertEqual(self.desc.license, 'GPL version 3 or later') + def suite(): suite = unittest.TestSuite() suite.addTest(TestDescription('test_re_depends')) suite.addTest(TestDescription('test_re_pkg_atom')) + suite.addTest(TestDescription('test_attributes')) return suite |