'Mock the methods needed for these tests.'

def setUp(self):

    super(TestViews, self).setUp()
    self.template_canary = u'canary'
    self.render_template = mock.Mock()
    self.render_template.return_value = self.template_canary
    self.block.runtime.render_template = self.render_template
    self.has_permission_mock = mock.Mock()
    self.has_permission_mock.return_value = False
    self.block.has_permission = self.has_permission_mock
