mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-03-11 06:43:54 +00:00
Talk about os.stat and tracebacks instead of Nevow
This commit is contained in:
parent
2ba34a4759
commit
816ca79d8a
@ -4767,11 +4767,9 @@ class Web(WebMixin, WebErrorMixin, testutil.StallMixin, testutil.ReallyEqualMixi
|
|||||||
def test_static_missing(self):
|
def test_static_missing(self):
|
||||||
# self.staticdir does not exist yet, because we used self.mktemp()
|
# self.staticdir does not exist yet, because we used self.mktemp()
|
||||||
d = self.assertFailure(self.GET("/static"), error.Error)
|
d = self.assertFailure(self.GET("/static"), error.Error)
|
||||||
# nevow.static throws an exception when it tries to os.stat the
|
# If os.stat raises an exception for the missing directory and the
|
||||||
# missing directory, which gives the client a 500 Internal Server
|
# traceback reveals the parent directory name we don't want to see
|
||||||
# Error, and the traceback reveals the parent directory name. By
|
# that parent directory name in the response. This addresses #1720.
|
||||||
# switching to plain twisted.web.static, this gives a normal 404 that
|
|
||||||
# doesn't reveal anything. This addresses #1720.
|
|
||||||
d.addCallback(lambda e: self.assertEquals(str(e), "404 Not Found"))
|
d.addCallback(lambda e: self.assertEquals(str(e), "404 Not Found"))
|
||||||
return d
|
return d
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user