code: def __configure_bigquery_env_from_credential_string(
      password: str, schema: str
  ) -> None:
      credential_string = password.replace("'", "")
      # `strict=False` required to work with BQ password characters.
      credentials = json.loads(credential_string, strict=False)
  
      assert isinstance(
          credentials, dict
      ), "JSON credential string did not parse to dict type!"
  
      bq_env = {
          DBT_ENV_SECRET_AUTH_PROVIDER_CERT_URL: credentials.get(
              "auth_provider_x509_cert_url"
          ),
          DBT_ENV_SECRET_AUTH_TYPE: credentials.get("type"),
          DBT_ENV_SECRET_AUTH_URI: credentials.get("auth_uri"),
          DBT_ENV_SECRET_CLIENT_CERT_URL: credentials.get(
              "client_x509_cert_url"
          ),
          DBT_ENV_SECRET_CLIENT_EMAIL: credentials.get("client_email"),
          DBT_ENV_SECRET_CLIENT_ID: credentials.get("client_id"),
          DBT_ENV_SECRET_PRIVATE_KEY: credentials.get("private_key"),
          DBT_ENV_SECRET_PRIVATE_KEY_ID: credentials.get(
              "private_key_id"
          ),
          DBT_ENV_SECRET_PROJECT_ID: credentials.get("project_id"),
          DBT_ENV_SECRET_TOKEN_URI: credentials.get("token_uri"),
      }
  
      empty_keys = [
          k for k, v in bq_env.items() if v is None or v == ""
      ]
  
      assert (
          not empty_keys
      ), f"BigQuery credentials did not contain all required values! Missing value for keys {empty_keys}."
  
      # Reconstruct the dict to refine the value type to str
      os.environ.update(
          {k: v for k, v in bq_env.items() if v is not None}
      )
      os.environ[DBT_ENV_SECRET_SCHEMA] = schema
  
imports: from __future__ import annotations
  import json
  import logging
  import os
  from typing import Generator
  import pytest
  import sqlalchemy
  from dbt.adapters.factory import get_adapter_by_type
  from dbt.cli.main import dbtRunner
  from metricflow.protocols.sql_client import SqlClient
  from metricflow.test.fixtures.setup_fixtures import MetricFlowTestSessionState, dbt_project_dir, dialect_from_url
  from metricflow.test.fixtures.sql_clients.adapter_backed_ddl_client import AdapterBackedDDLSqlClient
  from metricflow.test.fixtures.sql_clients.common_client import SqlDialect
  from metricflow.test.fixtures.sql_clients.ddl_sql_client import SqlClientWithDDLMethods
label_desc: Use image node_id 2 for calling a global function with example usage: __configure_bigquery_env_from_credential_string(password, schema) without return types