code: def test_train_skip_on_model_not_changed(
      run_in_simple_project_with_model: Callable[..., RunResult],
      tmp_path_factory: TempPathFactory,
  ):
      temp_dir = os.getcwd()
  
      models_dir = Path(temp_dir, "models")
      model_files = list(models_dir.glob("*"))
      assert len(model_files) == 1
      old_model = model_files[0]
  
      run_in_simple_project_with_model("train")
  
      model_files = list(sorted(models_dir.glob("*")))
      assert len(model_files) == 2
  
      new_model = model_files[1]
      assert old_model != new_model
  
      old_dir = tmp_path_factory.mktemp("old")
      _, old_metadata = LocalModelStorage.from_model_archive(
          old_dir, old_model
      )
  
      new_dir = tmp_path_factory.mktemp("new")
      _, new_metadata = LocalModelStorage.from_model_archive(
          new_dir, new_model
      )
  
      assert old_metadata.model_id != new_metadata.model_id
      assert old_metadata.trained_at < new_metadata.trained_at
      assert (
          old_metadata.domain.as_dict() == new_metadata.domain.as_dict()
      )
  
      assert rasa.utils.io.are_directories_equal(old_dir, new_dir)
  
imports: import os
  import sys
  from pathlib import Path
  from _pytest.capture import CaptureFixture
  import pytest
  from typing import Callable, List
  from _pytest.pytester import RunResult
  from _pytest.tmpdir import TempPathFactory
  import rasa.shared.utils.io
  from rasa.constants import NUMBER_OF_TRAINING_STORIES_FILE
  from rasa.core.policies.policy import Policy
  from rasa.engine.storage.local_model_storage import LocalModelStorage
  from rasa.engine.storage.resource import Resource
  from rasa.shared.core.domain import Domain
  from rasa.model_training import CODE_NEEDS_TO_BE_RETRAINED, CODE_FORCED_TRAINING
  from rasa.shared.constants import LATEST_TRAINING_DATA_FORMAT_VERSION
  from rasa.shared.nlu.training_data.training_data import DEFAULT_TRAINING_DATA_OUTPUT_PATH
  import rasa.utils.io
  from tests.cli.conftest import RASA_EXE
label_desc: Use image node_id 5 for calling a global function with example usage: test_train_skip_on_model_not_changed(run_in_simple_project_with_model, tmp_path_factory) without return types