func validateTotMemory(mem string) memory.MemSize {
	if mem == "" {
		fmt.Fprintf(os.Stderr, "-%s must be specified", totalFlag)
		os.Exit(1)
	}
	ms, err := memory.NewMemSizeFromString(mem)
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error in -%s flag: %s", totalFlag, err)
		os.Exit(1)
	}
	if ms.LessThan(memory.MemSize(1024)) {
		fmt.Fprintf(os.Stderr, "Total memory (-%s flag) is less than 1K", totalFlag)
		os.Exit(1)
	}
	return ms
}
			Ω(err).ShouldNot(HaveOccurred())
			return b
		}
	})

	Context("constructors", func() {

		Context("work", func() {
			It("with non-blank name and good weights", func() {
				b := shouldWork(memory.NewBucket("abucketname", 0.2, testRange))

				Ω(b.Name()).Should(Equal("abucketname"))
				Ω(b.Range()).Should(Equal(testRange))
				Ω(b.GetSize()).Should(BeNil())
				b.SetSize(124)
				Ω(*b.GetSize()).Should(Equal(memory.MemSize(124)))
				Ω(b.Weight()).Should(BeNumerically("~", 0.2))
				Ω(b.DefaultSize()).Should(Equal(memory.MEMSIZE_ZERO))
			})

			It("with 'stack' bucket and good weights", func() {
				sb := shouldWork(memory.NewBucket("stack", 0.1, testZeroRange))

				Ω(sb.Name()).Should(Equal("stack"))
				Ω(sb.DefaultSize()).Should(Equal(DEFAULT_JRE_STACK_SIZE))

				sb = shouldWork(memory.NewBucket("stack", 0.1, testRange))
				Ω(sb.DefaultSize()).Should(Equal(memory.NewMemSize(2 * mEGA)))
			})

			It("with spaced non-blank name", func() {