MCPcopy Create free account
hub / github.com/coder/envbuilder / checkTestRegistry

Function checkTestRegistry

integration/integration_test.go:2627–2641  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2625}
2626
2627func checkTestRegistry() {
2628 resp, err := http.Get("http://localhost:5000/v2/_catalog")
2629 if err != nil {
2630 _, _ = fmt.Printf("Check test registry: %s\n", err.Error())
2631 _, _ = fmt.Printf("Hint: Did you run `make test-registry`?\n")
2632 os.Exit(1)
2633 }
2634 defer resp.Body.Close()
2635 v := make(map[string][]string)
2636 if err := json.NewDecoder(resp.Body).Decode(&v); err != nil {
2637 _, _ = fmt.Printf("Read test registry catalog: %s\n", err.Error())
2638 _, _ = fmt.Printf("Hint: Did you run `make test-registry`?\n")
2639 os.Exit(1)
2640 }
2641}
2642
2643// cleanOldEnvbuilders removes any old envbuilder containers.
2644func cleanOldEnvbuilders() {

Callers 1

TestMainFunction · 0.85

Calls 2

ErrorMethod · 0.80
CloseMethod · 0.80

Tested by

no test coverage detected