suite: Test spark operator service account templates: - serviceaccount.yaml release: name: spark-operator tests: - it: Should not render service account if serviceAccounts.sparkoperator.create is false set: serviceAccounts: sparkoperator: create: false asserts: - hasDocuments: count: 0 - it: Should render service account if serviceAccounts.sparkoperator.create is true set: serviceAccounts: sparkoperator: create: true asserts: - containsDocument: apiVersion: v1 kind: ServiceAccount name: spark-operator - it: Should use the specified service account name if serviceAccounts.sparkoperator.name is set set: serviceAccounts: sparkoperator: name: custom-service-account asserts: - containsDocument: apiVersion: v1 kind: ServiceAccount name: custom-service-account - it: Should add extra annotations if serviceAccounts.sparkoperator.annotations is set set: serviceAccounts: sparkoperator: annotations: key1: value1 key2: value2 asserts: - equal: path: metadata.annotations.key1 value: value1 - equal: path: metadata.annotations.key2 value: value2