Added tests for graphs