def testRenderLiveFragment(self):
     """
     Test that L{render} spits out the right thing for a L{LiveFragment}.
     """
     self.assertIn(
         self.message,
         render(LiveFragment(docFactory=self.docFactory)))
Exemplo n.º 2
0
 def test_navPage(self):
     """
     Test that L{webapp.GenericNavigationLivePage} supports theming of
     Athena's unsupported-browser page based on an L{ITemplateNameResolver}
     installed on the viewing user's store.
     """
     subStore = SubStore.createNew(self.siteStore,
                                   ['athena', 'unsupported']).open()
     stp = StubThemeProvider(store=subStore)
     installOn(stp, subStore)
     p = GenericNavigationAthenaPage(
         stp, LiveFragment(), _PageComponents([], None, None, None, None),
         None)
     self.assertEqual(p.renderUnsupported(None), flatten(CUSTOM_MSG))