}) It("specifies the correct version", func() { Expect(initialBundle.Spec.Version).To(Equal("0.2.0")) }) Describe("WithHostname", func() { It("sets the Hostname in the bundle", func() { returnedBundle := initialBundle.WithHostname("hostname") Expect(returnedBundle.Hostname()).To(Equal("hostname")) }) }) Describe("WithCapabilities", func() { It("adds capabilities to the bundle", func() { returnedBundle := initialBundle.WithCapabilities("growtulips", "waterspuds") Expect(returnedBundle.Capabilities()).To(ContainElement("growtulips")) Expect(returnedBundle.Capabilities()).To(ContainElement("waterspuds")) }) It("does not modify the initial bundle", func() { returnedBundle := initialBundle.WithCapabilities("growtulips", "waterspuds") Expect(returnedBundle).NotTo(Equal(initialBundle)) }) }) Describe("WithProcess", func() { It("adds the process to the bundle", func() { returnedBundle := initialBundle.WithProcess(goci.Process("echo", "foo")) Expect(returnedBundle.Process()).To(Equal(specs.Process{Args: []string{"echo", "foo"}})) })