Esempio n. 1
0
 def setUp(self):
     TestCase.setUp(self)
     self.db = startup(populate=False)
Esempio n. 2
0
 def setUp(self):
     TestCase.setUp(self)
     self.db = startup(langs="en de fr")
Esempio n. 3
0
 def setUp(self):
     TestCase.setUp(self)
     self.db = startup()
Esempio n. 4
0
 def setUp(self):
     TestCase.setUp(self)
     self.db = startup()  # dump=True)
Esempio n. 5
0
 def setUp(self):
     TestCase.setUp(self)
     self.db = startup(withJokes=True)
Esempio n. 6
0
File: 28.py Progetto: vgrish/lino
 def setUp(self):
     TestCase.setUp(self)
     self.sess = startup()
Esempio n. 7
0
        if len(args) > 0:
            tcl=self.dbsess.getTableClass(args[0])
            if tcl is not None:
                rpt=self.dbsess.getViewReport(tcl,*args[1:],**kw)
                showReport(doc,rpt)
            else:
                doc.append(html.P(args[0]+" : no such table"))
                
            return self.endResponse()
        list=html.UL(); doc.append(list)
        for table in self.dbsess.db.app.getTableList():
            li=html.LI() ; list.append(li)
            li.append(html.A(table.getLabel(),
                             href="report/"+table.getTableName()))
            li.append(" (%d rows)" %
                len(self.dbsess.query(table._instanceClass)))

        return self.endResponse()

    report.exposed=True
    

    
syscon.setToolkit(HtmlServer())
sess = pinboard_demo.startup()
cherrypy.root = MyRoot(sess)

cherrypy.server.start()
sess.shutdown()