Add test for append and repair with partition simulator #33

Merged
shino merged 6 commits from ss-repair-with-partition-simulator into master 2015-11-04 05:44:04 +00:00
Showing only changes of commit 059f591d3f - Show all commits

View file

@ -937,7 +937,10 @@ update_proj2(Count, #state{bad_proj=BadProj, proxies_dict=ProxiesDict,
true -> true ->
Members = proplists:get_value(simulator_members, Opts, []), Members = proplists:get_value(simulator_members, Opts, []),
{Partitions, _Islands} = machi_partition_simulator:get(Members), {Partitions, _Islands} = machi_partition_simulator:get(Members),
[B || {A, B} <- Partitions, A =:= SimName]; lists:filtermap(fun({A, B}) when A =:= SimName -> {true, B};
({A, B}) when B =:= SimName -> {true, A};
(_) -> false
end, Partitions);
false -> [] false -> []
end, end,
Proxies = lists:foldl(fun(Name, Dict) -> Proxies = lists:foldl(fun(Name, Dict) ->