code: def test_process_spark_submit_log_yarn(self):
      # Given
      hook = SparkSubmitHook(conn_id="spark_yarn_cluster")
      log_lines = [
          "SPARK_MAJOR_VERSION is set to 2, using Spark2",
          "WARN NativeCodeLoader: Unable to load native-hadoop library for your "
          "platform... using builtin-java classes where applicable",
          "WARN DomainSocketFactory: The short-circuit local reads feature cannot "
          "be used because libhadoop cannot be loaded.",
          "INFO Client: Requesting a new application from cluster with 10 NodeManagers",
          "INFO Client: Submitting application application_1486558679801_1820 to ResourceManager",
      ]
      # When
      hook._process_spark_submit_log(log_lines)
  
      # Then
  
      assert (
          hook._yarn_application_id == "application_1486558679801_1820"
      )
  
imports: from __future__ import annotations
  import os
  from io import StringIO
  from unittest.mock import call, patch
  import pytest
  from airflow.exceptions import AirflowException
  from airflow.models import Connection
  from airflow.providers.apache.spark.hooks.spark_submit import SparkSubmitHook
  from airflow.utils import db
label_desc: Use image node_id 27 for calling the TestSparkSubmitHook obj's underlying member method code with example usage: obj.test_process_spark_submit_log_yarn() without return types