Ejemplo n.º 1
0
 def test_question_mark(self):
     assert _wildcard_match_path('test.txt', 'test.tx?')
     assert not _wildcard_match_path('test.bmp', 'test.tx?')
Ejemplo n.º 2
0
 def test_two_asterisks(self):
     assert _wildcard_match_path("directory/file.txt", "**.txt")
     assert not _wildcard_match_path("directory/file.bmp", "**.txt")
Ejemplo n.º 3
0
 def test_exact_match(self):
     assert _wildcard_match_path('text.txt', 'text.txt')
     assert not _wildcard_match_path('text.txt', 'toast.bmp')
Ejemplo n.º 4
0
 def test_asterisk(self):
     assert _wildcard_match_path("test.txt", "test*")
     assert not _wildcard_match_path("toast.txt", "test*")
Ejemplo n.º 5
0
 def test_asterisk_without_slash(self):
     assert _wildcard_match_path("directory/file.txt", "directory/*.txt")
     assert not _wildcard_match_path("directory/file.txt", "*.txt")
Ejemplo n.º 6
0
 def test_question_mark(self):
     assert _wildcard_match_path("test.txt", "test.tx?")
     assert not _wildcard_match_path("test.bmp", "test.tx?")
Ejemplo n.º 7
0
 def test_exact_match(self):
     assert _wildcard_match_path("text.txt", "text.txt")
     assert not _wildcard_match_path("text.txt", "toast.bmp")
Ejemplo n.º 8
0
 def test_two_asterisks(self):
     assert _wildcard_match_path('directory/file.txt', '**.txt')
     assert not _wildcard_match_path('directory/file.bmp', '**.txt')
Ejemplo n.º 9
0
 def test_asterisk_without_slash(self):
     assert _wildcard_match_path('directory/file.txt', 'directory/*.txt')
     assert not _wildcard_match_path('directory/file.txt', '*.txt')
Ejemplo n.º 10
0
 def test_asterisk(self):
     assert _wildcard_match_path('test.txt', 'test*')
     assert not _wildcard_match_path('toast.txt', 'test*')