本文整理汇总了Golang中github.com/concourse/atc/worker/fakes.FakeClient.LookupContainerArgsForCall方法的典型用法代码示例。如果您正苦于以下问题:Golang FakeClient.LookupContainerArgsForCall方法的具体用法?Golang FakeClient.LookupContainerArgsForCall怎么用?Golang FakeClient.LookupContainerArgsForCall使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类github.com/concourse/atc/worker/fakes.FakeClient
的用法示例。
在下文中一共展示了FakeClient.LookupContainerArgsForCall方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1:
Describe("before having created the container", func() {
BeforeEach(func() {
taskDelegate.InitializingStub = func(atc.TaskConfig) {
defer GinkgoRecover()
Ω(fakeWorkerClient.CreateContainerCallCount()).Should(BeZero())
}
})
It("invokes the delegate's Initializing callback", func() {
Ω(taskDelegate.InitializingCallCount()).Should(Equal(1))
Ω(taskDelegate.InitializingArgsForCall(0)).Should(Equal(fetchedConfig))
})
})
It("looked up the container via the session ID", func() {
Ω(fakeWorkerClient.LookupContainerArgsForCall(0)).Should(Equal(identifier))
})
It("gets the config from the input artifact soruce", func() {
Ω(configSource.FetchConfigCallCount()).Should(Equal(1))
Ω(configSource.FetchConfigArgsForCall(0)).Should(Equal(repo))
})
It("creates a container with the config's image and the session ID as the handle", func() {
Ω(fakeWorkerClient.CreateContainerCallCount()).Should(Equal(1))
createdIdentifier, spec := fakeWorkerClient.CreateContainerArgsForCall(0)
Ω(createdIdentifier).Should(Equal(identifier))
taskSpec := spec.(worker.TaskContainerSpec)
Ω(taskSpec.Platform).Should(Equal("some-platform"))
Ω(taskSpec.Tags).Should(ConsistOf("config", "step", "tags"))