code: def test_with_aliases():
      name = random_str()
      alias1 = RegisteredModelAlias("test_alias", "1")
      alias2 = RegisteredModelAlias("other_alias", "2")
      aliases = [alias1, alias2]
      as_dict = {
          "name": name,
          "creation_timestamp": 1,
          "last_updated_timestamp": 4000,
          "description": random_str(),
          "latest_versions": [],
          "tags": {},
          "aliases": aliases,
      }
      rmd_1 = RegisteredModel.from_dictionary(as_dict)
      as_dict["aliases"] = {
          alias.alias: alias.version for alias in (aliases or [])
      }
      assert dict(rmd_1) == as_dict
      proto = rmd_1.to_proto()
      assert proto.creation_timestamp == 1
      assert proto.last_updated_timestamp == 4000
      assert {alias.alias for alias in proto.aliases} == {
          "test_alias",
          "other_alias",
      }
      assert {alias.version for alias in proto.aliases} == {"1", "2"}
  
file_path: mlflow/tests/entities/model_registry/test_registered_model.py
imports: from mlflow.entities.model_registry import RegisteredModelAlias
  from mlflow.entities.model_registry.model_version import ModelVersion
  from mlflow.entities.model_registry.registered_model import RegisteredModel
  from mlflow.entities.model_registry.registered_model_tag import RegisteredModelTag
  from tests.helper_functions import random_str
label_desc: Use image node_id 5 for calling a global function with example usage: test_with_aliases() without return types