def METHOD_NAME(self):
    integer_attributes = [
        'T_BOOL',
        'T_BYTE', 'T_UBYTE',
        'T_SHORT', 'T_USHORT',
        'T_INT', 'T_UINT',
        'T_LONG', 'T_ULONG',
        'T_PYSSIZET'
        ]
    if hasattr(ts, 'T_LONGLONG'):
        integer_attributes.extend(['T_LONGLONG', 'T_ULONGLONG'])
    # issue8014: this produced 'bad argument to internal function'
    # internal error
    for nonint in None, 3.2j, "full of eels", {}, []:
        for attr in integer_attributes:
            self.assertRaises(TypeError, setattr, ts, attr, nonint)