Allura/allura/tests/functional/test_auth.py
def _create_password_reset_hash():
        """ Generates a password reset token for a given user.

        :return: User object
        :rtype: User
        """
        # test-user claimed email address
        user = M.User.by_username('test-admin')
        user.set_tool_data('AuthPasswordReset',
                           hash="generated_hash_value",
                           hash_expiry="04-08-2020")
        hash = user.get_tool_data('AuthPasswordReset', 'hash')
        session(user).flush(user)

        hash_expiry = user.get_tool_data('AuthPasswordReset', 'hash_expiry')
        assert_equal(hash, 'generated_hash_value')
        assert_equal(hash_expiry, '04-08-2020')
        return user
 Generates a password reset token for a given user.

        :return: User object
        :rtype: User
        
Generates a password reset token for a given user.
Generates a password reset token for a given user .
def _create_password_reset_hash():
        user = M.User.by_username('test-admin')
        user.set_tool_data('AuthPasswordReset',
                           hash="generated_hash_value",
                           hash_expiry="04-08-2020")
        hash = user.get_tool_data('AuthPasswordReset', 'hash')
        session(user).flush(user)
        hash_expiry = user.get_tool_data('AuthPasswordReset', 'hash_expiry')
        assert_equal(hash, 'generated_hash_value')
        assert_equal(hash_expiry, '04-08-2020')
        return user
def _create_password_reset_hash ( ) : user = M . User . by_username ( 'test-admin' ) user . set_tool_data ( 'AuthPasswordReset' , hash = "generated_hash_value" , hash_expiry = "04-08-2020" ) hash = user . get_tool_data ( 'AuthPasswordReset' , 'hash' ) session ( user ) . flush ( user ) hash_expiry = user . get_tool_data ( 'AuthPasswordReset' , 'hash_expiry' ) assert_equal ( hash , 'generated_hash_value' ) assert_equal ( hash_expiry , '04-08-2020' ) return user
Generates a password reset token for a given user.
Generates a password reset token for a given user .
""" Generates a password reset token for a given user.

        :return: User object
        :rtype: User
        """ # test-user claimed email address
None
User