test merge graphs