code: def test_spark_and_sklearn_autologging_all_runs_managed(
      spark_session, data_format, file_path
  ):
      mlflow.spark.autolog()
      mlflow.sklearn.autolog()
      for _ in range(2):
          with mlflow.start_run():
              df = (
                  spark_session.read.format(data_format)
                  .option("header", "true")
                  .option("inferSchema", "true")
                  .load(file_path)
                  .select("number1", "number2")
              )
              pandas_df = df.toPandas()
              run = _fit_sklearn_model(pandas_df)
          _assert_spark_data_logged(run, file_path, data_format)
      assert mlflow.active_run() is None
  
file_path: mlflow/tests/spark/autologging/datasource/test_spark_datasource_autologging_crossframework.py
imports: import time
  import numpy
  import pytest
  from sklearn.linear_model import LinearRegression
  import mlflow
  import mlflow.spark
  from tests.spark.autologging.utils import _assert_spark_data_logged
label_desc: Use image node_id 8 for calling a global function with example usage: test_spark_and_sklearn_autologging_all_runs_managed(spark_session, data_format, file_path) without return types