Added tests for graph syntax related changes.
Fixed one SQL syntax test. Part of @2082.