示例#1
0
def test_other_files(tmp_path, filter_str, expected):
    # let's create some files in tmp
    for fi in FILES:
        open(tmp_path / fi, 'a').close()
    actual = get_matching_files(tmp_path, filter_str)
    assert sorted(actual) == sorted(expected)
示例#2
0
def test_example_docstring(tmp_path, filter_str, expected):
    # let's create some files in tmp
    for fi in 'bite1 test output'.split():
        open(tmp_path / fi, 'a').close()
    actual = get_matching_files(tmp_path, filter_str)
    assert sorted(actual) == sorted(expected)