code: def test_endian_short(self):
      if sys.byteorder == "little":
          self.assertIs(c_short.__ctype_le__, c_short)
          self.assertIs(c_short.__ctype_be__.__ctype_le__, c_short)
      else:
          self.assertIs(c_short.__ctype_be__, c_short)
          self.assertIs(c_short.__ctype_le__.__ctype_be__, c_short)
      s = c_short.__ctype_be__(0x1234)
      self.assertEqual(bin(struct.pack(">h", 0x1234)), "1234")
      self.assertEqual(bin(s), "1234")
      self.assertEqual(s.value, 0x1234)
  
      s = c_short.__ctype_le__(0x1234)
      self.assertEqual(bin(struct.pack("<h", 0x1234)), "3412")
      self.assertEqual(bin(s), "3412")
      self.assertEqual(s.value, 0x1234)
  
      s = c_ushort.__ctype_be__(0x1234)
      self.assertEqual(bin(struct.pack(">h", 0x1234)), "1234")
      self.assertEqual(bin(s), "1234")
      self.assertEqual(s.value, 0x1234)
  
      s = c_ushort.__ctype_le__(0x1234)
      self.assertEqual(bin(struct.pack("<h", 0x1234)), "3412")
      self.assertEqual(bin(s), "3412")
      self.assertEqual(s.value, 0x1234)
  
file_path: catboost/contrib/tools/python/src/Lib/ctypes/test/test_byteswap.py
imports: import sys, unittest, struct, math, ctypes
  from binascii import hexlify
  from ctypes import *
label_desc: Use image node_id 2 for calling the Test obj's underlying member method code with example usage: obj.test_endian_short() without return types