(self)
| 276 | self.assertRaises(TypeError, msg.get_payload, 1) |
| 277 | |
| 278 | def test_decoded_generator(self): |
| 279 | eq = self.assertEqual |
| 280 | msg = self._msgobj('msg_07.txt') |
| 281 | with openfile('msg_17.txt', encoding="utf-8") as fp: |
| 282 | text = fp.read() |
| 283 | s = StringIO() |
| 284 | g = DecodedGenerator(s) |
| 285 | g.flatten(msg) |
| 286 | eq(s.getvalue(), text) |
| 287 | |
| 288 | def test__contains__(self): |
| 289 | msg = Message() |