self.GET(self.public_url + "/foo",
followRedirect=True))
def _check_page(res):
- # TODO: assert something about the contents
- pass
+ # TODO: assert more about the contents
+ self.failUnless("Overwrite" in res)
+ self.failUnless("Choose new file:" in res)
d.addCallback(_check_page)
return d
<td><n:slot name="size"/></td>
<td><n:slot name="data"/></td>
<td><n:slot name="delete"/></td>
- <td><div n:render="overwrite"/></td>
+ <td><n:slot name="overwrite"/></td>
<td><n:slot name="rename"/></td>
<td><n:slot name="check"/></td>
T.input(type='hidden', name='when_done', value=url.here),
T.input(type='submit', value='check', name="check"),
]
+ ctx.fillSlots("overwrite", self.build_overwrite(ctx, (name, target)))
ctx.fillSlots("check", check)
# build the base of the uri_link link url
T.div(class_="freeform-form")[mount],
]
- def render_overwrite(self, ctx, data):
+ def build_overwrite(self, ctx, data):
name, target = data
if IMutableFileNode.providedBy(target) and not target.is_readonly():
overwrite = T.form(action=".", method="post",