Happened something similar to me, with test_no_remote_user and
test_unknown_user.

It's been fixed in trunk: http://code.djangoproject.com/changeset/10674

The ticket was: http://code.djangoproject.com/ticket/10521


--
David Arcos Sebastián


On Mar 31, 4:35 pm, Filip Gruszczyński <grusz...@gmail.com> wrote:
> I haven't yet created any my own tests and just run ./manage.py test.
> This is what I got:
>
> ...FFFFFFFEEEEEEEEEEEE......
> ======================================================================
> ERROR: test_known_user
> (django.contrib.auth.tests.remote_user.RemoteUserCustomTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 159, in test_known_user
>     super(RemoteUserCustomTest, self).test_known_user()
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 66, in test_known_user
>     self.assertEqual(response.context['user'].username, 'knownuser')
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_last_login
> (django.contrib.auth.tests.remote_user.RemoteUserCustomTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 86, in test_last_login
>     self.assertNotEqual(default_login, response.context['user'].last_login)
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_no_remote_user
> (django.contrib.auth.tests.remote_user.RemoteUserCustomTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 32, in test_no_remote_user
>     self.assert_(isinstance(response.context['user'], AnonymousUser))
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_unknown_user
> (django.contrib.auth.tests.remote_user.RemoteUserCustomTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 167, in test_unknown_user
>     super(RemoteUserCustomTest, self).test_unknown_user()
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 50, in test_unknown_user
>     self.assertEqual(response.context['user'].username, 'newuser')
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_known_user
> (django.contrib.auth.tests.remote_user.RemoteUserNoCreateTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 66, in test_known_user
>     self.assertEqual(response.context['user'].username, 'knownuser')
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_last_login
> (django.contrib.auth.tests.remote_user.RemoteUserNoCreateTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 86, in test_last_login
>     self.assertNotEqual(default_login, response.context['user'].last_login)
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_no_remote_user
> (django.contrib.auth.tests.remote_user.RemoteUserNoCreateTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 32, in test_no_remote_user
>     self.assert_(isinstance(response.context['user'], AnonymousUser))
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_unknown_user
> (django.contrib.auth.tests.remote_user.RemoteUserNoCreateTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 117, in test_unknown_user
>     self.assert_(isinstance(response.context['user'], AnonymousUser))
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_known_user (django.contrib.auth.tests.remote_user.RemoteUserTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 66, in test_known_user
>     self.assertEqual(response.context['user'].username, 'knownuser')
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_last_login (django.contrib.auth.tests.remote_user.RemoteUserTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 86, in test_last_login
>     self.assertNotEqual(default_login, response.context['user'].last_login)
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_no_remote_user
> (django.contrib.auth.tests.remote_user.RemoteUserTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 32, in test_no_remote_user
>     self.assert_(isinstance(response.context['user'], AnonymousUser))
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> ERROR: test_unknown_user 
> (django.contrib.auth.tests.remote_user.RemoteUserTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File 
> "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/remote_user.py",
> line 50, in test_unknown_user
>     self.assertEqual(response.context['user'].username, 'newuser')
> TypeError: 'NoneType' object is unsubscriptable
>
> ======================================================================
> FAIL: test_confirm_complete 
> (django.contrib.auth.tests.views.PasswordResetTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 71, in test_confirm_complete
>     url, path = self._test_confirm_start()
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 32, in _test_confirm_start
>     self.assertEquals(response.status_code, 302)
> AssertionError: 200 != 302
>
> ======================================================================
> FAIL: test_confirm_different_passwords
> (django.contrib.auth.tests.views.PasswordResetTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 86, in test_confirm_different_passwords
>     url, path = self._test_confirm_start()
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 32, in _test_confirm_start
>     self.assertEquals(response.status_code, 302)
> AssertionError: 200 != 302
>
> ======================================================================
> FAIL: test_confirm_invalid (django.contrib.auth.tests.views.PasswordResetTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 49, in test_confirm_invalid
>     url, path = self._test_confirm_start()
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 32, in _test_confirm_start
>     self.assertEquals(response.status_code, 302)
> AssertionError: 200 != 302
>
> ======================================================================
> FAIL: test_confirm_invalid_post
> (django.contrib.auth.tests.views.PasswordResetTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 61, in test_confirm_invalid_post
>     url, path = self._test_confirm_start()
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 32, in _test_confirm_start
>     self.assertEquals(response.status_code, 302)
> AssertionError: 200 != 302
>
> ======================================================================
> FAIL: test_confirm_valid (django.contrib.auth.tests.views.PasswordResetTest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 42, in test_confirm_valid
>     url, path = self._test_confirm_start()
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 32, in _test_confirm_start
>     self.assertEquals(response.status_code, 302)
> AssertionError: 200 != 302
>
> ======================================================================
> FAIL: Email is sent if a valid email address is provided for password reset
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 25, in test_email_found
>     self.assertEquals(response.status_code, 302)
> AssertionError: 200 != 302
>
> ======================================================================
> FAIL: Error is raised if the provided email address isn't currently registered
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",
> line 17, in test_email_not_found
>     self.assertEquals(response.status_code, 200)
> AssertionError: 302 != 200
>
> ----------------------------------------------------------------------
> Ran 28 tests in 0.715s
>
> FAILED (failures=7, errors=12)
> Destroying test database...
>
> I have googled that and found this:http://code.djangoproject.com/ticket/8752
>
> I downloaded svn version hoping, that the patch is applied, but it
> wasn't. So I applied it, but this didn't work either. Have anyone
> experienced similar problems and knows, how to solve this?
>
> --
> Filip Gruszczyński
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to