Assert that ``lines2`` are contained (linearly) in :attr:`stringio`'s value. Lines are matched using :func:`LineMatcher.fnmatch_lines `.
(self, lines2: Sequence[str])
| 1510 | """:class:`python:io.StringIO()` instance used for input.""" |
| 1511 | |
| 1512 | def assert_contains_lines(self, lines2: Sequence[str]) -> None: |
| 1513 | """Assert that ``lines2`` are contained (linearly) in :attr:`stringio`'s value. |
| 1514 | |
| 1515 | Lines are matched using :func:`LineMatcher.fnmatch_lines <pytest.LineMatcher.fnmatch_lines>`. |
| 1516 | """ |
| 1517 | __tracebackhide__ = True |
| 1518 | val = self.stringio.getvalue() |
| 1519 | self.stringio.truncate(0) |
| 1520 | self.stringio.seek(0) |
| 1521 | lines1 = val.split("\n") |
| 1522 | LineMatcher(lines1).fnmatch_lines(lines2) |
| 1523 | |
| 1524 | |
| 1525 | class LineMatcher: |
no test coverage detected