Skip to content

Commit b0b6950

Browse files
committed
Add tests
1 parent d3c39d8 commit b0b6950

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

tests/test_glob.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,8 +1099,8 @@ def test_selflink(self):
10991099
depth += 1
11001100

11011101

1102-
class TestGlobRoot(unittest.TestCase):
1103-
"""Test `glob` at root of mount."""
1102+
class TestGlobPaths(unittest.TestCase):
1103+
"""Test `glob` paths."""
11041104

11051105
def test_root(self):
11061106
"""Test that `glob` translates the root properly."""
@@ -1110,6 +1110,14 @@ def test_root(self):
11101110
# Basically, we should not return an empty set.
11111111
self.assertTrue(len(glob.glob('/*')) > 0)
11121112

1113+
def test_start(self):
1114+
"""Test that starting directory/files are handled properly."""
1115+
1116+
self.assertEqual(
1117+
sorted(['docs', 'wcmatch', 'readme.md']),
1118+
sorted([each.lower() for each in glob.glob(['BAD', 'docs', 'WCMATCH', 'readme.MD'], flags=glob.I)])
1119+
)
1120+
11131121

11141122
class TestDeprecated(unittest.TestCase):
11151123
"""Test deprecated."""

0 commit comments

Comments
 (0)