~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/app/widgets/password.py

  • Committer: Launchpad Patch Queue Manager
  • Date: 2011-12-22 04:23:31 UTC
  • mfrom: (14564.4.2 megalint-7)
  • Revision ID: launchpad@pqm.canonical.com-20111222042331-ldeo5z018n8bq6x1
[r=jtv][no-qa] Lint.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright 2009 Canonical Ltd.  This software is licensed under the
 
1
# Copyright 2009-2011 Canonical Ltd.  This software is licensed under the
2
2
# GNU Affero General Public License version 3 (see the file LICENSE).
3
3
 
4
4
"""
79
79
        contain the same value. It returns the value encrypted.
80
80
 
81
81
        >>> request = LaunchpadTestRequest(form={
82
 
        ...     'field.foo': u'My Password', 'field.foo_dupe': u'My Password'}
83
 
        ...     )
 
82
        ...     'field.foo': u'My Password',
 
83
        ...     'field.foo_dupe': u'My Password',
 
84
        ...     })
84
85
        >>> widget = PasswordChangeWidget(field, request)
85
86
        >>> crypted_pw = widget.getInputValue()
86
87
        >>> encryptor = getUtility(IPasswordEncryptor)