chainloop_suite_test.go 759 B

12345678910111213141516171819202122232425262728293031
  1. package chainloop_test
  2. import (
  3. "flag"
  4. "testing"
  5. "time"
  6. . "github.com/onsi/ginkgo/v2"
  7. . "github.com/onsi/gomega"
  8. )
  9. var (
  10. kubeconfig string
  11. releaseName string
  12. namespace string
  13. timeoutSeconds int
  14. timeout time.Duration
  15. )
  16. func init() {
  17. flag.StringVar(&kubeconfig, "kubeconfig", "", "absolute path to the kubeconfig file")
  18. flag.StringVar(&releaseName, "name", "", "name of the primary statefulset")
  19. flag.StringVar(&namespace, "namespace", "", "namespace where the application is running")
  20. flag.IntVar(&timeoutSeconds, "timeout", 500, "timeout in seconds")
  21. timeout = time.Duration(timeoutSeconds) * time.Second
  22. }
  23. func TestChainloop(t *testing.T) {
  24. RegisterFailHandler(Fail)
  25. RunSpecs(t, "Chainloop Persistence Test Suite")
  26. }