docstr: Connection by decorator
docstr_tok: ["Connection","by","decorator"]
code: def test_decorator_connection(self):
      """Connection by decorator"""
      em = EventEmitter(type="test_event")
  
      @em.connect
      def cb(ev):
          self.result = 1
  
      self.result = None
      em()
      assert self.result == 1
  
imports: import unittest
  import copy
  import functools
  from vispy.util.event import Event, EventEmitter
  from vispy.testing import run_tests_if_main, assert_raises, assert_equal
label_desc: Use image node_id 11 for calling the TestEmitters obj's underlying member method code with example usage: obj.test_decorator_connection() without return types