ignore_test.go 520 B

1234567891011121314151617181920212223
  1. package gstruct_test
  2. import (
  3. . "github.com/onsi/ginkgo"
  4. . "github.com/onsi/gomega"
  5. . "github.com/onsi/gomega/gstruct"
  6. )
  7. var _ = Describe("Ignore", func() {
  8. It("should always succeed", func() {
  9. Expect(nil).Should(Ignore())
  10. Expect(struct{}{}).Should(Ignore())
  11. Expect(0).Should(Ignore())
  12. Expect(false).Should(Ignore())
  13. })
  14. It("should always fail", func() {
  15. Expect(nil).ShouldNot(Reject())
  16. Expect(struct{}{}).ShouldNot(Reject())
  17. Expect(1).ShouldNot(Reject())
  18. Expect(true).ShouldNot(Reject())
  19. })
  20. })