Skip to content

Commit

Permalink
add test_upath_property for descriptors
Browse files Browse the repository at this point in the history
  • Loading branch information
Reed O'Brien committed Mar 14, 2011
1 parent db2b5e4 commit 23eb217
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/test_descriptors.py
Expand Up @@ -39,3 +39,11 @@ def test_environ_getter_rfc_section():
eq_(desc.__doc__, "Gets and sets the 'akey' key in the environment. For "
"more information on akey see `section 14.3 "
"<http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.3>`_.")

def test_upath_property():
from webob.descriptors import upath_property
req = Request.blank('/')
desc = upath_property('akey')
eq_(desc.fget(req), '')
desc.fset(req, 'avalue')
eq_(desc.fget(req), 'avalue')

0 comments on commit 23eb217

Please sign in to comment.