[Checkins] SVN: gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/ pep8
Jan-Jaap Driessen
jdriessen at thehealthagency.com
Fri Dec 10 08:16:33 EST 2010
Log message for revision 118790:
pep8
Changed:
U gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/grok/tests.py
U gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/static/tests/test_static.py
U gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/testing.py
U gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/tests.py
-=-
Modified: gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/grok/tests.py
===================================================================
--- gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/grok/tests.py 2010-12-10 13:13:28 UTC (rev 118789)
+++ gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/grok/tests.py 2010-12-10 13:16:33 UTC (rev 118790)
@@ -44,5 +44,3 @@
gocept.selenium.grok.TestCase):
layer = test_layer
-
-
Modified: gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/static/tests/test_static.py
===================================================================
--- gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/static/tests/test_static.py 2010-12-10 13:13:28 UTC (rev 118789)
+++ gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/static/tests/test_static.py 2010-12-10 13:16:33 UTC (rev 118790)
@@ -12,6 +12,7 @@
#
##############################################################################
+import os
import unittest
import gocept.selenium.static
@@ -29,7 +30,6 @@
self.assert_(self.testlayer.documentroot.startswith('/tmp'))
def test_documentroot_initially_empty(self):
- import os
documentroot = self.testlayer.documentroot
self.assert_(not os.listdir(self.testlayer.documentroot))
open(os.path.join(documentroot, 'foo.txt'), 'w').write('Hello World!')
@@ -37,7 +37,6 @@
['foo.txt'], os.listdir(self.testlayer.documentroot))
def test_documentroot_empty_after_testsetup(self):
- import os
documentroot = self.testlayer.documentroot
self.assert_(not os.listdir(self.testlayer.documentroot))
open(os.path.join(documentroot, 'bar.txt'), 'w').write('Hello World!')
Modified: gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/testing.py
===================================================================
--- gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/testing.py 2010-12-10 13:13:28 UTC (rev 118789)
+++ gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/testing.py 2010-12-10 13:16:33 UTC (rev 118790)
@@ -36,15 +36,15 @@
elif path == '/colors.js':
statuscode = '200 OK'
headers.append(('Content-Type', 'text/javascript'))
- body = '''
- var hello = function hello () {
- document.getElementById('foo').innerHTML = 'Hello from javascript';
- };
- window.onload = hello;
- '''
+ body = '''\
+var hello = function hello () {
+ document.getElementById('foo').innerHTML = 'Hello from javascript';
+};
+window.onload = hello;'''
start_response(statuscode, headers)
return body
+
class SimpleApp2(object):
def __call__(self, environ, start_response):
Modified: gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/tests.py
===================================================================
--- gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/tests.py 2010-12-10 13:13:28 UTC (rev 118789)
+++ gocept.selenium/branches/janjaapdriessen-wsgi/src/gocept/selenium/wsgi/tests.py 2010-12-10 13:16:33 UTC (rev 118790)
@@ -27,6 +27,7 @@
self.selenium.open('/')
self.selenium.assertTextPresent('Hello from javascript')
+
class TestWSGILayerName(gocept.selenium.wsgi.TestCase):
""" We introduce a new test layer with a different application.
The name of the application is used in the name of the layer in order
More information about the checkins
mailing list