Exemplo n.º 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)
Exemplo n.º 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)
Exemplo n.º 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')
Exemplo n.º 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')