Permalink
Browse files

Fixes to tests busted by the introduction of CSSSource.

  • Loading branch information...
ralphbean committed Mar 13, 2012
1 parent 0fbed93 commit b795f3f2b68964d5d40908fc3004e4443274213d
Showing with 12 additions and 3 deletions.
  1. +10 −1 tests/test_commands.py
  2. +2 −2 tw2/core/resources.py
@@ -9,6 +9,8 @@
import shutil
import tempfile
from nose.tools import eq_
import tw2.core.core as core
import tw2.core.middleware as middleware
@@ -177,7 +179,14 @@ def test_load_no_widgets(self):
def test_load_entry_points(self):
self.c._load_widget_entry_points('tw2.forms')
rl_resources = core.request_local().setdefault('resources', [])
assert(len(rl_resources) == 3)
eq_(len(rl_resources), 4)
def test_render_entry_points(self):
self.c._load_widget_entry_points('tw2.forms')
rl_resources = core.request_local().setdefault('resources', [])
import pprint
print pprint.pformat(rl_resources)
def test_copy_tree(self):
import tw2.core.command
@@ -225,7 +225,7 @@ class JSSource(Resource):
"""
Inline JavaScript source code.
"""
src = pm.Param('Source code')
src = pm.Param('Source code', default=None)
location = 'bodybottom'
template = 'tw2.core.templates.jssource'
@@ -236,7 +236,7 @@ class CSSSource(Resource):
"""
Inline Cascading Style-Sheet code.
"""
src = pm.Param('CSS code')
src = pm.Param('CSS code', default=None)
location = 'head'
template = 'tw2.core.templates.csssource'

0 comments on commit b795f3f

Please sign in to comment.