summaryrefslogtreecommitdiff
path: root/pecan/tests/test_base.py
diff options
context:
space:
mode:
Diffstat (limited to 'pecan/tests/test_base.py')
-rw-r--r--pecan/tests/test_base.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/pecan/tests/test_base.py b/pecan/tests/test_base.py
index 6cc0f3c..a886a94 100644
--- a/pecan/tests/test_base.py
+++ b/pecan/tests/test_base.py
@@ -395,6 +395,11 @@ class TestControllerArguments(PecanTestCase):
', '.join(list(args) + data)
)
+ @staticmethod
+ @expose()
+ def static(id):
+ return "id is %s" % id
+
@expose()
def _route(self, args, request):
if hasattr(self, args[0]):
@@ -918,6 +923,11 @@ class TestControllerArguments(PecanTestCase):
assert r.status_int == 200
assert r.body == b_('variable_kwargs: list=%s' % l)
+ def test_staticmethod(self):
+ r = self.app_.get('/static/foobar')
+ assert r.status_int == 200
+ assert r.body == b_('id is foobar')
+
def test_no_remainder(self):
try:
r = self.app_.get('/eater')