Exemplo n.º 1
0
	Describe("Header", func() {
		It("returns nil if not initialized", func() {
			Ω(ctx.Header()).Should(BeNil())
		})
	})

	Describe("ResponseStatus", func() {
		It("returns 0 if not initialized", func() {
			Ω(ctx.ResponseStatus()).Should(Equal(0))
		})
	})

	Describe("ResponseLength", func() {
		It("returns 0 if not initialized", func() {
			Ω(ctx.ResponseLength()).Should(Equal(0))
		})
	})

	Describe("Get", func() {
		It(`returns "", false if not initialized`, func() {
			p := ctx.Get("foo")
			Ω(p).Should(Equal(""))
		})
	})

	Describe("GetMany", func() {
		It("returns nil if not initialized", func() {
			Ω(ctx.GetMany("foo")).Should(BeNil())
		})
	})
Exemplo n.º 2
0
	Describe("Header", func() {
		It("returns nil if not initialized", func() {
			Ω(ctx.Header()).Should(BeNil())
		})
	})

	Describe("ResponseStatus", func() {
		It("returns 0 if not initialized", func() {
			Ω(ctx.ResponseStatus()).Should(Equal(0))
		})
	})

	Describe("ResponseLength", func() {
		It("returns 0 if not initialized", func() {
			Ω(ctx.ResponseLength()).Should(Equal(0))
		})
	})

	Describe("Get", func() {
		It(`returns "", false if not initialized`, func() {
			p := ctx.Get("foo")
			Ω(p).Should(Equal(""))
		})
	})

	Describe("GetMany", func() {
		It("returns nil if not initialized", func() {
			Ω(ctx.GetMany("foo")).Should(BeNil())
		})
	})