code: def test_cstrings(self):
      # c_char_p.from_param on a Python String packs the string
      # into a cparam object
      s = b"123"
      self.assertIs(c_char_p.from_param(s)._obj, s)
  
      # new in 0.9.1: convert (encode) unicode to ascii
      self.assertEqual(c_char_p.from_param(b"123")._obj, b"123")
      self.assertRaises(TypeError, c_char_p.from_param, "123\377")
      self.assertRaises(TypeError, c_char_p.from_param, 42)
  
      # calling c_char_p.from_param with a c_char_p instance
      # returns the argument itself:
      a = c_char_p(b"123")
      self.assertIs(c_char_p.from_param(a), a)
  
imports: import _ctypes_test
  import unittest
  import test.support
  from ctypes import CDLL, PyDLL, ArgumentError, Structure, Array, Union, _Pointer, _SimpleCData, _CFuncPtr, POINTER, pointer, byref, c_void_p, c_char_p, c_wchar_p, py_object, c_bool, c_char, c_wchar, c_byte, c_ubyte, c_short, c_ushort, c_int, c_uint, c_long, c_ulong, c_longlong, c_ulonglong, c_float, c_double, c_longdouble
label_desc: Use image node_id 5 for calling the SimpleTypesTestCase obj's underlying member method code with example usage: obj.test_cstrings() without return types