TestIntegration_WindowFunctions tests window function support across dialects
(t *testing.T)
| 307 | |
| 308 | // TestIntegration_WindowFunctions tests window function support across dialects |
| 309 | func TestIntegration_WindowFunctions(t *testing.T) { |
| 310 | projectRoot, _ := filepath.Abs(filepath.Join("..", "..")) |
| 311 | files := loadSQLTestFiles(t, projectRoot) |
| 312 | |
| 313 | windowFiles := []SQLTestFile{} |
| 314 | for _, file := range files { |
| 315 | if strings.Contains(strings.ToLower(file.Content), "over") && |
| 316 | (strings.Contains(strings.ToLower(file.Content), "partition") || |
| 317 | strings.Contains(strings.ToLower(file.Content), "row_number") || |
| 318 | strings.Contains(strings.ToLower(file.Content), "rank")) { |
| 319 | windowFiles = append(windowFiles, file) |
| 320 | } |
| 321 | } |
| 322 | |
| 323 | if len(windowFiles) == 0 { |
| 324 | t.Skip("No window function test files found") |
| 325 | } |
| 326 | |
| 327 | t.Logf("Found %d files with window functions", len(windowFiles)) |
| 328 | runTestBatch(t, windowFiles, "Window Functions") |
| 329 | } |
| 330 | |
| 331 | // TestIntegration_CTEs tests Common Table Expression support |
| 332 | func TestIntegration_CTEs(t *testing.T) { |
nothing calls this directly
no test coverage detected