I am using the django.contrib.auth and came across the following error:
Creating test database for alias 'default'...
...EE..
======================================================================
ERROR: test_create (new_way.core.tests.test_models.EmployeeTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/rg3915/git/my/new_way_project/new_way/core/tests/test_models.py", line 121, in setUp
comission=180.5
File "/home/rg3915/git/my/new_way_project/lib/python3.4/site-packages/django/db/models/base.py", line 452, in __init__
raise TypeError("'%s' is an invalid keyword argument for this function" % list(kwargs)[0])
TypeError: 'birthday' is an invalid keyword argument for this function
======================================================================
ERROR: test_has_created_at (new_way.core.tests.test_models.EmployeeTest)
Employee must have automatic created_at
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/rg3915/git/my/new_way_project/new_way/core/tests/test_models.py", line 121, in setUp
comission=180.5
File "/home/rg3915/git/my/new_way_project/lib/python3.4/site-packages/django/db/models/base.py", line 452, in __init__
raise TypeError("'%s' is an invalid keyword argument for this function" % list(kwargs)[0])
TypeError: 'birthday' is an invalid keyword argument for this function
----------------------------------------------------------------------
Ran 7 tests in 0.010s
FAILED (errors=2)
Destroying test database for alias 'default'...
See my models.
I suspect this error related to the User.
Aucun commentaire:
Enregistrer un commentaire