def test_invalid_values(self): di = DiscInfo() di.timestamp = "foo" di.description = "Fedora 21" di.arch = "x86_64" di.disc_numbers = ["ALL"] self.assertRaises(TypeError, di.dumps)
def test_disc_numbers(self): di = DiscInfo() di.timestamp = 1386856788.124593 di.description = "Fedora 20" di.arch = "x86_64" di.disc_numbers = [1, "2", 3] di.dump(self.path) self._test_identity(di)
def test_all(self): di = DiscInfo() di.now() di.description = "Fedora 20" di.arch = "x86_64" di.disc_numbers = ["ALL"] di.dump(self.path) self._test_identity(di)