code: def test_alpha_int8():
      assert Color("rgba(0, 0, 0, 1)").alpha_int8 == 255
      assert Color("rgba(0, 0, 0, 0)").alpha_int8 == 0
      if not (
          Color("rgb(127,0,0)").red_quantum
          <= Color("rgba(0,0,0,0.5").alpha_quantum
          <= Color("rgb(128,0,0)").red_quantum
      ):
          # FIXME: I don't know why, but the value PixelGetAlphaQuantum() returns
          #        is inconsistent to other PixelGet{Red,Green,Blue}Quantum()
          #        functions in Travis CI.  We just skip the test in this case.
          return
      assert 127 <= Color("rgba(0, 0, 0, 0.5)").alpha_int8 <= 128
      c = Color("none")
      c.alpha_int8 = 255
      assert c.alpha_int8 == 255
  
imports: import ctypes
  import time
  import warnings
  from pytest import mark, raises
  from wand.color import Color
  from wand.compat import xrange
  from wand.version import QUANTUM_DEPTH, MAGICK_VERSION_INFO
label_desc: Use image node_id 26 for calling a global function with example usage: test_alpha_int8() without return types