(dir string, goDirPath string)
| 184 | } |
| 185 | |
| 186 | return database.Ping() |
| 187 | } |
| 188 | |
| 189 | var cachedDevBuildPath = "" |
| 190 | |
| 191 | func initializeDevBuild(dir string, goDirPath string) string { |
| 192 | if cachedDevBuildPath != "" { |
| 193 | return cachedDevBuildPath |
| 194 | } |
| 195 | |
| 196 | // If we're not in a CI environment, don't worry about building a dev build |
| 197 | if os.Getenv("CI") != "true" { |
| 198 | return "" |
| 199 | } |
| 200 | |
| 201 | basedir := filepath.Dir(filepath.Dir(dir)) |
| 202 | fullpath := filepath.Join(basedir, fmt.Sprintf("dev-build-%d", os.Getpid())) |
| 203 | |
| 204 | _, err := os.Stat(fullpath) |
| 205 | if err == nil { |
| 206 | return fullpath |
| 207 | } |
| 208 | |
| 209 | fmt.Printf("building dev build at: %s \n", fullpath) |
| 210 | cmd := exec.Command("go", "build", "-tags=duckdb_arrow", "-o", fullpath) |
| 211 | cmd.Dir = goDirPath |
| 212 | |
| 213 | output, err := cmd.CombinedOutput() |
| 214 | if err != nil { |
| 215 | panic("unable to build dolt for binlog integration tests: " + err.Error() + "\nFull output: " + string(output) + "\n") |
| 216 | } |
| 217 | cachedDevBuildPath = fullpath |
| 218 |
no outgoing calls
no test coverage detected