Test RequireInvalidSQL with valid SQL
(t *testing.T)
| 122 | |
| 123 | // Test RequireInvalidSQL with valid SQL |
| 124 | func TestRequireInvalidSQL_Valid(t *testing.T) { |
| 125 | mockT := &mockTestingT{} |
| 126 | |
| 127 | RequireInvalidSQL(mockT, "SELECT * FROM users") |
| 128 | |
| 129 | if !mockT.fataled { |
| 130 | t.Error("RequireInvalidSQL should fatal for valid SQL") |
| 131 | } |
| 132 | if !strings.Contains(mockT.fatalMsg, "Required invalid SQL") { |
| 133 | t.Errorf("Fatal message should be descriptive, got: %s", mockT.fatalMsg) |
| 134 | } |
| 135 | } |
| 136 | |
| 137 | // Test AssertFormattedSQL with matching format |
| 138 | func TestAssertFormattedSQL_Matching(t *testing.T) { |
nothing calls this directly
no test coverage detected