Message134600
| Author |
okopnik |
| Recipients |
eric.araujo, okopnik |
| Date |
2011年04月27日.17:27:44 |
| SpamBayes Score |
0.0001663586 |
| Marked as misclassified |
No |
| Message-id |
<1303925265.82.0.276365644012.issue11914@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Trivial fix: please see attached. As to test_pydoc.py, I don't know the system well enough to fiddle with it, but something like this should work (untested):
def test_unreadable_dir(self):
''' pydoc should handle unreadable subdirs gracefully '''
@contextmanager
def mk_unreadable_dir():
top_level_dir = tempfile.mkdtemp()
bad_dir = tempfile.mkdtemp(dir=top_level_dir)
os.chmod(bad_dir, 0)
os.chdir(top_level_dir)
yield
os.removedirs(top_level_dir)
with mk_unreadable_dir():
doc = pydoc.render_doc('modules')
self.assertTrue("modules" in doc) |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2011年04月27日 17:27:45 | okopnik | set | recipients:
+ okopnik, eric.araujo |
| 2011年04月27日 17:27:45 | okopnik | set | messageid: <1303925265.82.0.276365644012.issue11914@psf.upfronthosting.co.za> |
| 2011年04月27日 17:27:44 | okopnik | link | issue11914 messages |
| 2011年04月27日 17:27:44 | okopnik | create |
|