本文整理匯總了Golang中github.com/concourse/baggageclaim/fakes.FakeVolume.PropertiesReturns方法的典型用法代碼示例。如果您正苦於以下問題:Golang FakeVolume.PropertiesReturns方法的具體用法?Golang FakeVolume.PropertiesReturns怎麽用?Golang FakeVolume.PropertiesReturns使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類github.com/concourse/baggageclaim/fakes.FakeVolume
的用法示例。
在下文中一共展示了FakeVolume.PropertiesReturns方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。
示例1:
TTL: time.Hour,
ResourceVersion: atc.Version{"some": "theversion"},
ResourceHash: "hash",
}))
})
It("releases the volume, since the container keeps it alive", func() {
Expect(foundVolume.ReleaseCallCount()).To(Equal(1))
})
Describe("the cache", func() {
Describe("IsInitialized", func() {
Context("when the volume has the initialized property set", func() {
BeforeEach(func() {
foundVolume.PropertiesReturns(baggageclaim.VolumeProperties{
"initialized": "any-value",
}, nil)
})
It("returns true", func() {
Expect(initCache.IsInitialized()).To(BeTrue())
})
})
Context("when the volume has no initialized property", func() {
BeforeEach(func() {
foundVolume.PropertiesReturns(baggageclaim.VolumeProperties{}, nil)
})
It("returns false", func() {
initialized, err := initCache.IsInitialized()