def _test_file_path(basename, format=None):
    """Return the full path to an example filename in the 'examples'
    directory."""
    if format is not None:
        file_extension = format_manager().file_extension(format)
        filename = basename + '.' + format + file_extension
    else:
        # format=None ==> .py test file
        filename = basename + '.py'
    return op.realpath(op.join(_script_dir(), '../../../examples', filename))
Return the full path to an example filename in the 'examples'
    directory.
ipymd/formats/tests/_utils.py