INNER CODE UNIT · Go

initialize

go-chassis/go-chassis · bootstrap/bootstrap_test.go:24

func initialize(t *testing.T) {
	os.Setenv("CHASSIS_HOME", "/tmp/")
	t.Cleanup(func() {
		os.Unsetenv("CHASSIS_HOME")
	})
	chassisConf := filepath.Join("/tmp/", "conf")
	os.MkdirAll(chassisConf, 0700)
	os.Create(filepath.Join(chassisConf, "chassis.yaml"))
	os.Create(filepath.Join(chassisConf, "microservice.yaml"))
}

func (b *bootstrapPlugin) Init() error {
	success[b.Name] = true
	return nil
}

func TestBootstrap(t *testing.T) {
	initialize(t)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…