}) It("does not change the container's state", func() { Expect(container.State()).To(Equal(linux_backend.StateBorn)) err := container.Start() Expect(err).To(HaveOccurred()) Expect(container.State()).To(Equal(linux_backend.StateBorn)) }) }) }) Describe("Stopping", func() { It("executes the container's stop.sh with the appropriate arguments", func() { err := container.Stop(false) Expect(err).ToNot(HaveOccurred()) Expect(fakeRunner).To(HaveExecutedSerially( fake_command_runner.CommandSpec{ Path: containerDir + "/stop.sh", }, )) }) It("sets the container's state to stopped", func() { Expect(container.State()).To(Equal(linux_backend.StateBorn)) err := container.Stop(false) Expect(err).ToNot(HaveOccurred())