def METHOD_NAME(self):
    cases = [
        ("dir", "dir", True),
        ("dir", "file", False),
        ("dir", "dir/file", False),
        ("dir/*.txt", "file", False),
        ("dir/*.txt", "dir/file", False),
        ("dir/*.txt", "dir/file.txt", True),
        ("dir/*.txt", "dir/.txt", True),
        (os.path.join("dir", "**", "*.txt"), os.path.join("dir", "a.txt"), True),
        (os.path.join("dir", "**", "*.txt"), os.path.join("dir", "sub", "a.txt"), True),
        (os.path.join("dir", "**", "*.txt"), os.path.join("dir", "sub", "sub", "a.txt"), True),
        (os.path.join("dir", "**", "*.txt"), os.path.join("dir", "sub", "sub", "a.obj"), False),
        (os.path.join("dir", "**", "*"), os.path.join("dir", "sub", "sub", "sub", "a.txt"), True),
        (os.path.join("dir", "**", "*"), os.path.join("dir", "sub", "sub", "a.bob"), True),
        (os.path.join("dir", "**", "*"), os.path.join("dir", "sub", "z.o"), True),
        (os.path.join("dir", "**", "*"), os.path.join("dir", "abc"), True),
    ]
    for case in cases:
        matcher = GlobMatcher(case[0])
        msg = "Pattern: %s, Path: %s, expected: %s, got: %s" % (
            case[0],
            case[1],
            case[2],
            not case[2],
        )
        self.assertEqual(matcher.matches(case[1]), case[2], msg)
    with self.assertRaises(ValueError):
        GlobMatcher(os.path.join(".", "blah", "**", "blah", "**", "*.txt"))