(t *testing.T)
| 242 | } |
| 243 | |
| 244 | func TestNestedFunctionCallPosition(t *testing.T) { |
| 245 | tree := parseWithPositions(t, "SELECT SUM(amount) FROM orders") |
| 246 | |
| 247 | sel := tree.Statements[0].(*ast.SelectStatement) |
| 248 | |
| 249 | fn, ok := sel.Columns[0].(*ast.FunctionCall) |
| 250 | if !ok { |
| 251 | t.Fatalf("expected *ast.FunctionCall, got %T", sel.Columns[0]) |
| 252 | } |
| 253 | |
| 254 | assertPos(t, "FunctionCall(SUM).Pos", fn.Pos) |
| 255 | } |
| 256 | |
| 257 | // ----------------------------------------------------------------------------- |
| 258 | // TestBinaryExpressionPosition verifies BinaryExpression nodes carry positions |
nothing calls this directly
no test coverage detected