def test_dict(self): """ Test that dictionaries are correctly identified. """ self.n = bencode.ben_type("d3:key5:valuee") self.assertEqual(self.n, dict)
def test_string(self): """ Test that strings are correctly identified. """ self.n = bencode.ben_type("4:test") self.assertEqual(self.n, str)
def test_list(self): """ Test that lists are correctly identified. """ self.n = bencode.ben_type("l4:teste") self.assertEqual(self.n, list)
def test_integers(self): """ Test that integers are correctly identified. """ self.n = bencode.ben_type("i1e") self.assertEqual(self.n, int)