Verify that an unknown encoding is still read as latin-1.
(tmpdir, default_options)
| 42 | |
| 43 | |
| 44 | def test_read_lines_unknown_encoding(tmpdir, default_options): |
| 45 | """Verify that an unknown encoding is still read as latin-1.""" |
| 46 | lines = _lines_from_file( |
| 47 | tmpdir, b"# coding: fake-encoding\nx = 1\n", default_options, |
| 48 | ) |
| 49 | assert lines == ["# coding: fake-encoding\n", "x = 1\n"] |
| 50 | |
| 51 | |
| 52 | @pytest.mark.parametrize( |
nothing calls this directly
no test coverage detected