code: def check_eq(self, result, obj1, obj2):
      if result:
          assert obj1 == obj2
          assert obj2 == obj1
          assert not (obj1 != obj2)
          assert not (obj2 != obj1)
      else:
          assert obj1 != obj2
          assert obj2 != obj1
          assert not (obj1 == obj2)
          assert not (obj2 == obj1)
  
imports: import re
  import threading
  import unittest
  import pytest
  import cupy
  from cupy import cuda
  from cupy import testing
label_desc: Use image node_id 1 for calling the TestDeviceComparison obj's underlying member method code with example usage: obj.check_eq(result, obj1, obj2) without return types