Did I find the right examples for you? yes no

All Samples(2)  |  Call(2)  |  Derive(0)  |  Import(0)

src/c/l/cloudbase-init-HEAD/cloudbaseinit/tests/plugins/windows/test_setuserpassword.py   cloudbase-init(Download)
            mock_service.get_admin_password.assert_called_with()
        else:
            mock_osutils.generate_random_password.assert_called_once_with(14)
        self.assertEqual(response, 'Passw0rd')
 

src/c/l/cloudbase-init-HEAD/cloudbaseinit/tests/plugins/windows/test_createuser.py   cloudbase-init(Download)
    def test_get_password(self):
        mock_osutils = mock.MagicMock()
        mock_osutils.generate_random_password.return_value = 'fake password'
        response = self._create_user._get_password(mock_osutils)
        mock_osutils.generate_random_password.assert_called_once_with(14)