• Home
  • Raw
  • Download

Lines Matching refs:ts

14 ts=_test_structmembersType(False,  # T_BOOL  variable
32 ts.T_BOOL = True
33 self.assertEqual(ts.T_BOOL, True)
34 ts.T_BOOL = False
35 self.assertEqual(ts.T_BOOL, False)
36 self.assertRaises(TypeError, setattr, ts, 'T_BOOL', 1)
39 ts.T_BYTE = CHAR_MAX
40 self.assertEqual(ts.T_BYTE, CHAR_MAX)
41 ts.T_BYTE = CHAR_MIN
42 self.assertEqual(ts.T_BYTE, CHAR_MIN)
43 ts.T_UBYTE = UCHAR_MAX
44 self.assertEqual(ts.T_UBYTE, UCHAR_MAX)
47 ts.T_SHORT = SHRT_MAX
48 self.assertEqual(ts.T_SHORT, SHRT_MAX)
49 ts.T_SHORT = SHRT_MIN
50 self.assertEqual(ts.T_SHORT, SHRT_MIN)
51 ts.T_USHORT = USHRT_MAX
52 self.assertEqual(ts.T_USHORT, USHRT_MAX)
55 ts.T_INT = INT_MAX
56 self.assertEqual(ts.T_INT, INT_MAX)
57 ts.T_INT = INT_MIN
58 self.assertEqual(ts.T_INT, INT_MIN)
59 ts.T_UINT = UINT_MAX
60 self.assertEqual(ts.T_UINT, UINT_MAX)
63 ts.T_LONG = LONG_MAX
64 self.assertEqual(ts.T_LONG, LONG_MAX)
65 ts.T_LONG = LONG_MIN
66 self.assertEqual(ts.T_LONG, LONG_MIN)
67 ts.T_ULONG = ULONG_MAX
68 self.assertEqual(ts.T_ULONG, ULONG_MAX)
71 ts.T_PYSSIZET = PY_SSIZE_T_MAX
72 self.assertEqual(ts.T_PYSSIZET, PY_SSIZE_T_MAX)
73 ts.T_PYSSIZET = PY_SSIZE_T_MIN
74 self.assertEqual(ts.T_PYSSIZET, PY_SSIZE_T_MIN)
76 @unittest.skipUnless(hasattr(ts, "T_LONGLONG"), "long long not present")
78 ts.T_LONGLONG = LLONG_MAX
79 self.assertEqual(ts.T_LONGLONG, LLONG_MAX)
80 ts.T_LONGLONG = LLONG_MIN
81 self.assertEqual(ts.T_LONGLONG, LLONG_MIN)
83 ts.T_ULONGLONG = ULLONG_MAX
84 self.assertEqual(ts.T_ULONGLONG, ULLONG_MAX)
87 ts.T_LONGLONG = 3
88 self.assertEqual(ts.T_LONGLONG, 3)
89 ts.T_ULONGLONG = 4
90 self.assertEqual(ts.T_ULONGLONG, 4)
101 if hasattr(ts, 'T_LONGLONG'):
108 self.assertRaises(TypeError, setattr, ts, attr, nonint)
111 self.assertEqual(ts.T_STRING_INPLACE, "hi")
112 self.assertRaises(TypeError, setattr, ts, "T_STRING_INPLACE", "s")
113 self.assertRaises(TypeError, delattr, ts, "T_STRING_INPLACE")
120 ts.T_BYTE = CHAR_MAX+1
124 ts.T_BYTE = CHAR_MIN-1
128 ts.T_UBYTE = UCHAR_MAX+1
132 ts.T_SHORT = SHRT_MAX+1
136 ts.T_SHORT = SHRT_MIN-1
140 ts.T_USHORT = USHRT_MAX+1