validation_test.yaml 933 B

1234567891011121314151617181920212223242526272829303132333435
  1. suite: persistence validation test
  2. templates:
  3. - common.yaml
  4. tests:
  5. - it: should fail with pod targetSelector not a map
  6. set:
  7. workload:
  8. main:
  9. enabled: true
  10. primary: true
  11. type: Deployment
  12. podSpec: {}
  13. persistence:
  14. volume1:
  15. enabled: true
  16. targetSelector: not-a-map
  17. asserts:
  18. - failedTemplate:
  19. errorMessage: Persistence - Expected <targetSelector> to be [dict], but got [string]
  20. - it: should fail with invalid type
  21. set:
  22. workload:
  23. main:
  24. enabled: true
  25. primary: true
  26. type: Deployment
  27. podSpec: {}
  28. persistence:
  29. volume1:
  30. enabled: true
  31. type: not-a-type
  32. asserts:
  33. - failedTemplate:
  34. errorMessage: Persistence - Expected <type> to be one of [emptyDir, hostPath, ixVolume, secret, configmap, device], but got [not-a-type]