| 880 | eq(msg['content-transfer-encoding'], '7bit') |
| 881 | |
| 882 | def test_default_cte(self): |
| 883 | eq = self.assertEqual |
| 884 | # 7bit data and the default us-ascii _charset |
| 885 | msg = MIMEText('hello world') |
| 886 | eq(msg['content-transfer-encoding'], '7bit') |
| 887 | # Similar, but with 8bit data |
| 888 | msg = MIMEText('hello \xf8 world') |
| 889 | eq(msg['content-transfer-encoding'], 'base64') |
| 890 | # And now with a different charset |
| 891 | msg = MIMEText('hello \xf8 world', _charset='iso-8859-1') |
| 892 | eq(msg['content-transfer-encoding'], 'quoted-printable') |
| 893 | |
| 894 | @unittest.expectedFailure # TODO: RUSTPYTHON; LookupError: unknown encoding: iso-2022-jp |
| 895 | def test_encode7or8bit(self): |