tests for graphs