##// END OF EJS Templates
Merge pull request #1917 from takluyver/i1914...
Min RK -
r7464:01d7b933 merge
parent child Browse files
Show More
@@ -354,7 +354,7 b' class Inspector:'
354 354 if inspect.isclass(obj):
355 355 header = self.__head('Class constructor information:\n')
356 356 obj = obj.__init__
357 elif type(obj) is types.InstanceType:
357 elif (not py3compat.PY3) and type(obj) is types.InstanceType:
358 358 obj = obj.__call__
359 359
360 360 output = self._getdef(obj,oname)
@@ -283,3 +283,8 b' def test_getdoc():'
283 283 nt.assert_equal(oinspect.getdoc(a), "standard docstring")
284 284 nt.assert_equal(oinspect.getdoc(b), "custom docstring")
285 285 nt.assert_equal(oinspect.getdoc(c), "standard docstring")
286
287 def test_pdef():
288 # See gh-1914
289 def foo(): pass
290 inspector.pdef(foo, 'foo')
General Comments 0
You need to be logged in to leave comments. Login now