Ejemplo n.º 1
0
	consulNameOverrideStub string
)

var _ = BeforeSuite(func() {
	goPath = helpers.SetupGoPath()
	gemfilePath := helpers.SetupFastBosh()
	config = helpers.LoadConfig()
	boshOperationTimeout := helpers.GetBoshOperationTimeout(config)
	bosh = helpers.NewBosh(gemfilePath, goPath, config.BoshTarget, boshOperationTimeout)

	consulManifestGeneration = filepath.Join(goPath, "src", "acceptance-tests", "scripts", "generate-consul-deployment-manifest")

	err := os.Chdir(goPath)
	Expect(err).ToNot(HaveOccurred())

	directorUUIDStub = bosh.TargetDeployment()
	createConsulStub()
	bosh.CreateAndUploadRelease(goPath, consulRelease)
})

var _ = AfterSuite(func() {
	if bosh == nil {
		return
	}

	By("delete release")
	bosh.Command("-n", "delete", "release", consulRelease)
})

func createConsulStub() {
	By("creating the consul overrides stub")