code: def test_alter_return_none():
      """Test doing nothing by returning 'None'"""
  
      def before():
          x = relay.var("x", shape=(1, 64, 56, 56))
          y = relay.nn.global_max_pool2d(x)
          y = relay.Function([x], y)
          return y
  
      called = [False]
  
      def alter_conv2d(attrs, inputs, tinfos, out_type):
          called[0] = True
          return None
  
      with TempOpAttr(
          "nn.global_max_pool2d", "FTVMAlterOpLayout", alter_conv2d
      ):
          a = before()
          a = run_opt_pass(a, transform.AlterOpLayout())
          b = run_opt_pass(before(), transform.InferType())
  
      assert tvm.ir.structural_equal(a, b), "Actual = \n" + str(a)
      assert called[0]
  
imports: import pytest
  import tvm
  from tvm import relay, topi
  from tvm.relay import transform, analysis
  from tvm.relay.testing.temp_op_attr import TempOpAttr
  from tvm.relay.testing import run_infer_type
  import numpy
  import tvm.testing
  from tvm.relay import testing
label_desc: Use image node_id 3 for calling a global function with example usage: test_alter_return_none() and returns: y, None