def METHOD_NAME(self):
    # checks that mount_pvc respects previously set secrets
    @dsl.pipeline
    def my_pipeline():
        task = comp()
        kubernetes.use_secret_as_env(
            task,
            secret_name='secret-name',
            secret_key_to_env={'password': 'SECRET_VAR'},
        )
        kubernetes.mount_pvc(
            task,
            pvc_name='pvc-name',
            mount_path='path',
        )
    assert json_format.MessageToDict(my_pipeline.platform_spec) == {
        'platforms': {
            'kubernetes': {
                'deploymentSpec': {
                    'executors': {
                        'exec-comp': {
                            'pvcMount': [{
                                'constant': 'pvc-name',
                                'mountPath': 'path'
                            }],
                            'secretAsEnv': [{
                                'secretName':
                                    'secret-name',
                                'keyToEnv': [{
                                    'secretKey': 'password',
                                    'envVar': 'SECRET_VAR'
                                }]
                            }]
                        }
                    }
                }
            }
        }
    }