(t *testing.T)
| 81 | } |
| 82 | |
| 83 | func TestBug1_ErrorPositionOnSecondLine(t *testing.T) { |
| 84 | // Error is deliberately on line 2 to verify the line counter advances. |
| 85 | sql := "SELECT 1;\nSELECT FROM users" |
| 86 | err := parseExpectError(t, sql) |
| 87 | |
| 88 | // The error string must mention line 2 somewhere. |
| 89 | if !strings.Contains(err.Error(), "line 2") { |
| 90 | t.Errorf("expected error to reference line 2, got: %v", err) |
| 91 | } |
| 92 | } |
| 93 | |
| 94 | func TestBug1_ErrorPositionColumnNonZero(t *testing.T) { |
| 95 | // "SELECT id, FROM users" - the stray comma/FROM creates a parser error. |
nothing calls this directly
no test coverage detected