code: def test_delete_registered_model_flow(client):
      name = "DeleteRMTest"
      start_time_1 = get_current_time_millis()
      client.create_registered_model(name)
      end_time_1 = get_current_time_millis()
      registered_model_detailed_1 = client.get_registered_model(name)
      assert registered_model_detailed_1.name == name
      assert_is_between(
          start_time_1,
          end_time_1,
          registered_model_detailed_1.creation_timestamp,
      )
      assert_is_between(
          start_time_1,
          end_time_1,
          registered_model_detailed_1.last_updated_timestamp,
      )
  
      assert [
          rm.name
          for rm in client.search_registered_models()
          if rm.name == name
      ] == [name]
  
      # cannot create a model with same name
      with pytest.raises(
          MlflowException, match=r"Registered Model .+ already exists"
      ):
          client.create_registered_model(name)
  
      client.delete_registered_model(name)
  
      # cannot get a deleted model
      with pytest.raises(
          MlflowException, match=r"Registered Model .+ not found"
      ):
          client.get_registered_model(name)
  
      # cannot update a deleted model
      with pytest.raises(
          MlflowException, match=r"Registered Model .+ not found"
      ):
          client.rename_registered_model(
              name=name, new_name="something else"
          )
  
      # list does not include deleted model
      assert [
          rm.name
          for rm in client.search_registered_models()
          if rm.name == name
      ] == []
  
      # recreate model with same name
      start_time_2 = get_current_time_millis()
      client.create_registered_model(name)
      end_time_2 = get_current_time_millis()
      registered_model_detailed_2 = client.get_registered_model(name)
      assert registered_model_detailed_2.name == name
      assert_is_between(
          start_time_2,
          end_time_2,
          registered_model_detailed_2.creation_timestamp,
      )
      assert_is_between(
          start_time_2,
          end_time_2,
          registered_model_detailed_2.last_updated_timestamp,
      )
  
      assert [
          rm.name
          for rm in client.search_registered_models()
          if rm.name == name
      ] == [name]
  
imports: import time
  import pytest
  from mlflow import MlflowClient
  from mlflow.entities.model_registry import ModelVersion, RegisteredModel
  from mlflow.exceptions import MlflowException
  from mlflow.utils.os import is_windows
  from mlflow.utils.time import get_current_time_millis
  from tests.tracking.integration_test_utils import _init_server
label_desc: Use image node_id 7 for calling a global function with example usage: test_delete_registered_model_flow(client) without return types