def test_plugin(self, mock_random):
print cherrypy.engine.publish
hashes = cherrypy.engine.publish('password-hash', 'changeme').pop()
self.assertIsInstance(hashes, dict)
self.assertEqual(hashes['userPassword'], '{SSHA}6QBuyak4WbsUzcqUKx0yB74RFUFvDbys')
self.assertEqual(hashes['sambaNTPassword'], '6597D9FE8469E21D840E2CBFF8D43C8B')
评论列表
文章目录