ยปCore Development>Code coverage>Lib/test/inspect_fodder.py

Python code coverage for Lib/test/inspect_fodder.py

#countcontent
1n/a# line 1
2n/a'A module docstring.'
3n/a
4n/aimport sys, inspect
5n/a# line 5
6n/a
7n/a# line 7
8n/adef spam(a, b, c, d=3, e=4, f=5, *g, **h):
9n/a eggs(b + d, c + f)
10n/a
11n/a# line 11
12n/adef eggs(x, y):
13n/a "A docstring."
14n/a global fr, st
15n/a fr = inspect.currentframe()
16n/a st = inspect.stack()
17n/a p = x
18n/a q = y / 0
19n/a
20n/a# line 20
21n/aclass StupidGit:
22n/a """A longer,
23n/a
24n/a indented
25n/a
26n/a docstring."""
27n/a# line 27
28n/a
29n/a def abuse(self, a, b, c):
30n/a """Another
31n/a
32n/a\tdocstring
33n/a
34n/a containing
35n/a
36n/a\ttabs
37n/a\t
38n/a """
39n/a self.argue(a, b, c)
40n/a# line 40
41n/a def argue(self, a, b, c):
42n/a try:
43n/a spam(a, b, c)
44n/a except:
45n/a self.ex = sys.exc_info()
46n/a self.tr = inspect.trace()
47n/a
48n/a @property
49n/a def contradiction(self):
50n/a 'The automatic gainsaying.'
51n/a pass
52n/a
53n/a# line 53
54n/aclass MalodorousPervert(StupidGit):
55n/a def abuse(self, a, b, c):
56n/a pass
57n/a
58n/a @property
59n/a def contradiction(self):
60n/a pass
61n/a
62n/aTit = MalodorousPervert
63n/a
64n/aclass ParrotDroppings:
65n/a pass
66n/a
67n/aclass FesteringGob(MalodorousPervert, ParrotDroppings):
68n/a def abuse(self, a, b, c):
69n/a pass
70n/a
71n/a @property
72n/a def contradiction(self):
73n/a pass
74n/a
75n/aasync def lobbest(grenade):
76n/a pass