changeset 26:feeb97e8c23c

example/persona.py
author Jeff Hammel <jhammel@mozilla.com>
date Thu, 26 Dec 2013 21:18:15 -0800
parents e5efb021a8e6
children b411066b4929
files example/persona.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/example/persona.py	Thu Dec 26 20:11:30 2013 -0800
+++ b/example/persona.py	Thu Dec 26 21:18:15 2013 -0800
@@ -17,7 +17,10 @@
 class PersonaTest(object):
     def __init__(self, page):
         self.page = page or globals()['page']
-        assert os.path.exists(self.page)
+        assert os.path.exists(self.page), "File '%s' not found" % self.page
+        self.page = open(self.page, 'r').read()
+    def __call__(self, environ, start_response):
+        raise NotImplementedError
 
 def main(args=sys.argv[1:]):