MCPcopy
hub / github.com/StevenBlack/hosts / test_write_unicode

Method test_write_unicode

testUpdateHostsFile.py:1781–1790  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1779 self.assertEqual(actual, expected)
1780
1781 def test_write_unicode(self):
1782 f = BytesIO()
1783
1784 data = u"foo"
1785 write_data(f, data)
1786
1787 expected = b"foo"
1788 actual = f.getvalue()
1789
1790 self.assertEqual(actual, expected)
1791
1792
1793class TestQueryYesOrNo(BaseStdout):

Callers

nothing calls this directly

Calls 1

write_dataFunction · 0.90

Tested by

no test coverage detected