docstr: Waits and asserts a successful KFP pipeline execution.
  
  Args:
    host: the endpoint of the KFP deployment.
    run_id: the run ID of the execution, can be obtained from the respoonse
      when submitting the pipeline.
    pipeline_name: the name of the pipeline under test.
    timeout: maximal waiting time for this execution, in timedelta.
  
  Raises:
    RuntimeError: when timeout exceeds after waiting for specified duration.
docstr_tok: ["Waits","and","asserts","a","successful","KFP","pipeline","execution",".","Args",":","host",":","the","endpoint","of","the","KFP","deployment",".","run_id",":","the","run","ID","of","the","execution",",","can","be","obtained","from","the","respoonse","when","submitting","the","pipeline",".","pipeline_name",":","the","name","of","the","pipeline","under","test",".","timeout",":","maximal","waiting","time","for","this","execution",",","in","timedelta",".","Raises",":","RuntimeError",":","when","timeout","exceeds","after","waiting","for","specified","duration","."]
code: def _assert_successful_run_completion(
      self,
      host: str,
      run_id: str,
      pipeline_name: str,
      timeout: datetime.timedelta,
  ):
      """Waits and asserts a successful KFP pipeline execution.
  
      Args:
        host: the endpoint of the KFP deployment.
        run_id: the run ID of the execution, can be obtained from the respoonse
          when submitting the pipeline.
        pipeline_name: the name of the pipeline under test.
        timeout: maximal waiting time for this execution, in timedelta.
  
      Raises:
        RuntimeError: when timeout exceeds after waiting for specified duration.
      """
  
      status = kubeflow_test_utils.poll_kfp_with_retry(
          host=host,
          run_id=run_id,
          retry_limit=self._N_RETRIES,
          timeout=timeout,
          polling_interval=self._POLLING_INTERVAL,
      )
  
      workflow_log = self._get_workflow_log(pipeline_name)
  
      self.assertEqual(
          status.lower(),
          kubeflow_test_utils.KFP_SUCCESS_STATUS,
          "Pipeline %s failed to complete successfully: %s"
          % (pipeline_name, workflow_log),
      )
  
imports: import datetime
  import os
  import subprocess
  from absl import logging
  import kfp
  import tensorflow
  from tfx.dsl.io import fileio
  from tfx.examples.penguin import penguin_kubeflow_gcp
  from tfx.orchestration import data_types
  from tfx.orchestration import pipeline
  from tfx.orchestration import test_utils
  from tfx.orchestration.kubeflow import kubeflow_dag_runner
  from tfx.orchestration.kubeflow import test_utils
label_desc: Use image node_id 4 for calling the KubeflowGcpPerfTest obj's underlying member method code with example usage: obj._assert_successful_run_completion(host, run_id, pipeline_name, timeout) without return types