'</td>\s+<td>DIR-RO</td>', res))
d.addCallback(_check3)
+ # and an empty directory
+ d.addCallback(lambda res: self.GET(self.public_url + "/foo/empty/"))
+ def _check4(res):
+ self.failUnless("directory is empty!" in res, res)
+ d.addCallback(_check4)
+
return d
def test_GET_DIRURL_badtype(self):
def render_try_children(self, ctx, data):
# if the dirnode can be retrived, render a table of children.
# Otherwise, render an apologetic error message.
- if self.dirnode_children:
+ if self.dirnode_children is not None:
return ctx.tag
else:
return T.div[T.p["Error reading directory:"],