``pytester`` learned two new functions, `no_fnmatch_line `_ and `no_re_match_line `_. The functions are used to ensure the captured text *does not* match the given pattern. The previous idiom was to use ``re.match``: .. code-block:: python assert re.match(pat, result.stdout.str()) is None Or the ``in`` operator: .. code-block:: python assert text in result.stdout.str() But the new functions produce best output on failure.