Files
OctoPrint/tests/access/users/test_usermanager.py
T
MirceaDan f243a52823 all files start now with same 2 lines
# coding=utf-8
from __future__ import absolute_import, division, print_function
2018-12-02 02:13:12 -08:00

27 lines
682 B
Python

# coding=utf-8
from __future__ import absolute_import, division, print_function
"""
Unit tests for octoprint.users.UserManager
"""
__license__ = 'GNU Affero General Public License http://www.gnu.org/licenses/agpl.html'
__copyright__ = "Copyright (C) 2017 The OctoPrint Project - Released under terms of the AGPLv3 License"
import unittest
import ddt
import octoprint.access.users
@ddt.ddt
class UserManagerTest(unittest.TestCase):
def test_createPasswordHash_nonascii(self):
"""Test for issue #1891"""
password = u"password with ümläutß"
salt = "abc"
# should not throw an exception
octoprint.access.users.UserManager.create_password_hash(password, salt=salt)