code: def test__native_dist_model_init_method_is_not_none(
      world_size, local_rank, get_fixed_dirname
  ):
      init_method = f"file://{get_fixed_dirname('native_dist_model_init_method_is_not_none')}/shared"
      with pytest.raises(
          ValueError,
          match=r"Both rank and world_size should be provided",
      ):
          _NativeDistModel.create_from_backend(
              backend="gloo",
              world_size=world_size,
              init_method=init_method,
          )
  
      with pytest.raises(
          ValueError,
          match=r"Both rank and world_size should be provided",
      ):
          _NativeDistModel.create_from_backend(
              backend="gloo", rank=local_rank, init_method=init_method
          )
  
imports: import os
  import pytest
  import torch
  import torch.distributed
  from ignite.distributed.comp_models import has_native_dist_support
label_desc: Use image node_id 28 for calling a global function with example usage: test__native_dist_model_init_method_is_not_none(world_size, local_rank, get_fixed_dirname) without return types