code: def test_bytescale_mask(self):
      a = np.ma.MaskedArray(data=[1, 2, 3], mask=[False, False, True])
      with suppress_warnings() as sup:
          sup.filter(DeprecationWarning)
          actual = misc.bytescale(a)
      expected = [0, 255, 3]
      assert_equal(expected, actual)
      assert_mask_equal(a.mask, actual.mask)
      assert_(isinstance(actual, np.ma.MaskedArray))
  
imports: from __future__ import division, print_function, absolute_import
  import os.path
  import tempfile
  import shutil
  import numpy
  import glob
  import pytest
  from pytest import raises
  from numpy.testing import assert_equal, assert_allclose, assert_array_equal, assert_
  from scipy._lib._numpy_compat import suppress_warnings
  from scipy import misc
  from numpy.ma.testutils import assert_mask_equal
label_desc: Use image node_id 9 for calling the TestPILUtil obj's underlying member method code with example usage: obj.test_bytescale_mask() without return types