Test cases and better graph interface