def test_should_return_empty_string_if_no_common_path_was_found(self):
     assert base_path_for_file_list(
         ['a://base/path/1/file', 'b://base/path/2/file']) == ''
 def test_should_return_common_path_ignoring_partial_name_match(self):
     assert base_path_for_file_list(
         ['/base/path/file1', '/base/path/file2']) == '/base/path'
 def test_should_return_common_path_of_two_files_using_forward_slash(self):
     assert base_path_for_file_list(
         ['\\base\\path\\1\\file',
          '\\base\\path\\2\\file']) == '\\base\\path'
 def test_should_return_common_path_of_two_files_using_protocol(self):
     assert base_path_for_file_list(
         ['a://base/path/1/file',
          'a://base/path/2/file']) == 'a://base/path'
 def test_should_return_common_path_of_two_files(self):
     assert base_path_for_file_list(
         ['/base/path/1/file', '/base/path/2/file']) == '/base/path'
 def test_should_return_parent_directory_of_single_file(self):
     assert base_path_for_file_list(['/base/path/1/file']) == '/base/path/1'
 def test_should_return_empty_string_if_filename_is_empty(self):
     assert base_path_for_file_list(['']) == ''