Closed carmenbianca closed 3 months ago
Also, this test fails, but according to the 3.2 draft spec it should work:
def test_match_asterisk(self):
"""Match everything in local directory."""
item = AnnotationsItem(paths=["*"])
assert item.matches("foo.py")
assert item.matches(".gitignore")
assert not item.matches("src/foo.py")
assert not item.matches(".foo/bar")
Something with *
feels broken. I tested reuse convert-dep5
on the curl repository. While the REUSE.toml file looks good, reuse does not detect the files covered by asterisks, e.g. path = ["tests/data/test*", "tests/certs/*"]
My hypothesis is that *
is broken when it's the final character. This makes sense when I remember my implementation.
See the tests here: https://github.com/fsfe/reuse-tool/blob/7ab812407cb62b590d0a646546b1cfa7b4661e66/tests/test_global_licensing.py#L228
There should be tests for raw
*
and raw**
.