code: def test_downcast_nullable_mask_is_copied():
      # GH38974
  
      arr = pd.array([1, 2, pd.NA], dtype="Int64")
  
      result = to_numeric(arr, downcast="integer")
      expected = pd.array([1, 2, pd.NA], dtype="Int8")
      tm.assert_extension_array_equal(result, expected)
  
      arr[1] = pd.NA  # should not modify result
      tm.assert_extension_array_equal(result, expected)
  
imports: import decimal
  import numpy
  from numpy import iinfo
  import pytest
  import pandas.util._test_decorators
  import pandas
  from pandas import ArrowDtype, DataFrame, Index, Series, option_context, to_numeric
  import pandas._testing
label_desc: Use image node_id 51 for calling a global function with example usage: test_downcast_nullable_mask_is_copied() without return types