added tests to graph reduce