Exemple #1
0
def test_collision_check_raises(file_map):
    with mock.patch('os.path.exists') as exists:
        exists.return_value = True
        with pytest.raises(blind.ConflictError):
            result = blind._collision_check(file_map)
Exemple #2
0
def test_collision_check_raises(file_map):
    with mock.patch('os.path.exists') as exists:
        exists.return_value = True
        with pytest.raises(blind.ConflictError):
            result = blind._collision_check(file_map)
Exemple #3
0
def test_collision_check(file_map):
    with mock.patch('os.path.exists') as exists:
        exists.return_value = False
        result = blind._collision_check(file_map)
        exists.assert_any_call('one.txt.masked')
        exists.assert_any_call('two.txt.masked')
Exemple #4
0
def test_collision_check(file_map):
    with mock.patch('os.path.exists') as exists:
        exists.return_value = False
        result = blind._collision_check(file_map)
        exists.assert_any_call('one.txt.masked')
        exists.assert_any_call('two.txt.masked')