It("Has 1 row", func() { Ω(ds.NumRows()).To(Equal(1)) }) Context("When getting a row", func() { Context("When the index is correct", func() { It("Consistently returns the correct row", func() { newRow, err = ds.Row(0) Ω(err).ShouldNot(HaveOccurred()) newRowAgain, err := ds.Row(0) Ω(err).ShouldNot(HaveOccurred()) Ω(newRow.Features().Equals(newRowAgain.Features())).Should(BeTrue()) Ω(newRow.Target().Equals(newRowAgain.Target())).Should(BeTrue()) }) }) Context("When the index is correct", func() { It("Returns an error", func() { _, err = ds.Row(-1) Ω(err).Should(HaveOccurred()) newRow, err = ds.Row(1) Ω(err).Should(HaveOccurred()) }) }) }) }) })