suite: persistence pvc name test
templates:
  - common.yaml
release:
  name: test-release-name
  namespace: test-release-namespace
tests:
  - it: should generate correct name
    set:
      persistence:
        my-volume1:
          enabled: true
          type: pvc
        my-volume2:
          enabled: true
          type: pvc
    asserts:
      - documentIndex: &pvcDoc 0
        isKind:
          of: PersistentVolumeClaim
      - documentIndex: *pvcDoc
        isAPIVersion:
          of: v1
      - documentIndex: *pvcDoc
        equal:
          path: metadata.name
          value: test-release-name-common-test-my-volume1
      - documentIndex: &otherPvcDoc 1
        isKind:
          of: PersistentVolumeClaim
      - documentIndex: *otherPvcDoc
        isAPIVersion:
          of: v1
      - documentIndex: *otherPvcDoc
        equal:
          path: metadata.name
          value: test-release-name-common-test-my-volume2
