Marc Tamlyn
4755f8fc25
Fixed #24343 -- Ensure db converters are used for foreign keys.
...
Joint effort between myself, Josh, Anssi and Shai.
2015-02-20 11:35:51 +00:00
Tim Graham
c8074d62f8
Fixed typo in error message in the test.
2015-02-19 19:36:20 -05:00
Aymeric Augustin
1bfcc950ab
Set context.template instead of context.engine while rendering.
...
This opens more possibilities, like accessing context.template.origin.
It also follows the chain of objects instead of following a shortcut.
2015-02-19 22:08:11 +01:00
Claude Paroz
efb1f99f94
Fixed #20889 -- Prevented BadHeaderError when Python inserts newline
...
Workaround for http://bugs.python.org/issue20747 .
In some corner cases, Python 2 inserts a newline in a header value
despite `maxlinelen` passed in Header constructor.
Thanks Tim Graham for the review.
2015-02-19 20:18:31 +01:00
Shai Berger
ceadc94f09
Fixed #24307 : Avoided redundant column nullability modifications on Oracle
...
Thanks Joris Benschop for the report, and Tim Graham for the tests.
2015-02-19 02:39:41 +02:00
Shai Berger
f7d34fe741
Fixed #24362 : Made test run each migration operation in its own schema editor
...
Thanks Tim Graham for pointing out the fix.
2015-02-18 22:47:15 +02:00
Marten Kenbeek
15dc8d1c9d
Fixed #24291 - Fixed migration ModelState generation with unused swappable models
...
Swapped out models don't have a _default_manager unless they have
explicitly defined managers. ModelState.from_model() now accounts for
this case and uses an empty list for managers if no explicit managers
are defined and a model is swapped out.
2015-02-18 19:05:10 +01:00
Tim Graham
b8d6cdbcc9
Refs #24324 -- Skipped fixtures_regress tests that fail on Python 2 on a non-ASCII path.
2015-02-18 07:25:36 -05:00
Tim Graham
307c0f299a
Refs #24324 -- Fixed Python 2 test failures when path to Django source contains non-ASCII characters.
2015-02-17 19:03:03 -05:00
Tim Graham
ad50b6c853
Fixed "environment can only contain strings" in model_regress test on Windows.
2015-02-17 13:54:18 -05:00
Tim Graham
d316b43d0a
Refs #24324 -- Fixed UnicodeDecodeError in model_regress test on non-ASCII path.
2015-02-17 07:32:48 -05:00
Tim Graham
8b39f33d78
Fixed #24290 -- Skipped postgres_tests if not running with PostgreSQL.
2015-02-17 06:34:13 -05:00
Tim Graham
3adc5f1ee6
Fixed #24335 -- Bumped required psycopg2 version to 2.4.5 (2.5 for contrib.postgres).
2015-02-16 18:07:27 -05:00
Tim Graham
664c038f2c
Moved contrib.contenttypes tests out of contrib.
2015-02-16 17:45:38 -05:00
Markus Holtermann
d538e37e1b
Added tests for get_related_models_recursive
2015-02-16 19:31:52 +01:00
Markus Holtermann
273bc4b667
Refs #24282 -- Added failing test case for assigning models of wrong type to FK
...
Thanks Jeff Singer for the test case.
2015-02-16 19:31:51 +01:00
Markus Holtermann
cc22b009e0
Refs #24264 -- Added failing test case for updating a FK when changing a PK
...
When the primary key column is altered, foreign keys of referencing
models must be aware of a possible data type change as well and thus
need to be re-rendered.
Thanks Tim Graham for the report.
2015-02-16 19:31:51 +01:00
Claude Paroz
58d0dd9260
Refs #24225 -- Added failing test case for removing a previously added field in migrations
...
When a related field is deleted, the related model must be updated. As
unchanged models are shared in migration states, the related model must
be re-rendered so that the change applies to a new copy of the related
model.
Thanks Henrik Heimbuerger for the report.
2015-02-16 19:31:51 +01:00
Marten Kenbeek
f668bac9d2
Fixed #24345 -- Isolated sitemaps_tests from contenttypes_tests; refs #11505
2015-02-16 08:42:43 -05:00
Loic Bistuer
c5a77721e2
Merged ManyRelatedObjectsDescriptor and ReverseManyRelatedObjectsDescriptor
...
and made all "many" related objects descriptors inherit from
ForeignRelatedObjectsDescriptor.
2015-02-16 20:40:04 +07:00
Aymeric Augustin
15b711b5ee
Deprecated TEMPLATE_DEBUG setting.
2015-02-15 20:47:04 +01:00
Tim Graham
e0b3926026
Isolated auth_tests from contenttypes_tests; refs #11505 .
2015-02-14 22:04:48 -05:00
Michael Angeletti
49647bec6e
Added missing return value to DurationField.prepare_value(); refs #24339 .
2015-02-14 18:38:50 -05:00
Aymeric Augustin
76356d963c
Fixed #24318 -- Set the transaction isolation level with psycopg >= 2.4.2.
2015-02-14 18:51:11 +01:00
Michael Angeletti
8a21d25033
Fixed #24339 -- Fixed crash with empty DurationField form field.
2015-02-14 07:37:18 -05:00
Claude Paroz
1791a7e75a
Fixed #15779 -- Allowed 'add' primary key in admin edition
...
Thanks Marwan Alsabbagh for the report, and Simon Charette and
Tim Graham for the reviews.
2015-02-14 11:19:55 +01:00
Aymeric Augustin
47ee7b48ad
Fixed #24338 -- Accepted Template wrapper in {% extends %}.
...
Explicitly checking for django.template.Template subclasses is
preferrable to duck-typing because both the django.template.Template and
django.template.backends.django.Template have a render() method.
Thanks spectras for the report.
2015-02-14 10:21:06 +01:00
Loic Bistuer
18c0aaa912
Fixed #24289 -- Reversed usage of Field.many_to_one and one_to_many.
...
Thanks Carl Meyer and Tim Graham for the reviews and to all involved
in the discussion.
2015-02-14 02:28:24 +07:00
Andriy Sokolovskiy
5c995dcfc2
Fixed #24320 - Used field.value_to_string() in serialization of foreign key.
...
This fixes serialization of a ForeignKey to a UUIDField as the
test indicates.
2015-02-13 12:37:23 -05:00
Tim Graham
002425fe39
Fixed #24315 -- Fixed auth.views.password_reset_confirm() with a UUID user.
2015-02-13 09:56:31 -05:00
Tim Graham
fdf20093e0
Fixed #24334 -- Allowed admin password reset to work with non-digit custom user model primary key.
...
Thanks Loic for help and Simon for review.
2015-02-13 09:42:49 -05:00
Markus Holtermann
f287bec583
Fixed #24184 -- Prevented automatic soft-apply of migrations
...
Previously Django only checked for the table name in CreateModel
operations in initial migrations and faked the migration automatically.
This led to various errors and unexpected behavior. The newly introduced
--fake-initial flag to the migrate command must be passed to get the
same behavior again. With this change Django will bail out in with a
"duplicate relation / table" error instead.
Thanks Carl Meyer and Tim Graham for the documentation update, report
and review.
2015-02-13 14:29:59 +01:00
Markus Holtermann
b4e1090ab2
Removed explicit pointers to migration modules for contrib apps in runtest
...
Thanks Tim Graham for the patch
2015-02-13 14:29:45 +01:00
Markus Holtermann
b06935a486
Refs #22962 -- Made test case use non-conflicting table names
2015-02-13 14:01:54 +01:00
Loic Bistuer
00a889167f
Fixed #24295 -- Allowed ModelForm meta to specify form field classes.
...
Thanks Carl Meyer and Markus Holtermann for the reviews.
2015-02-13 19:13:05 +07:00
Tim Graham
e8cf4f8abe
Fixed #24332 -- Fixed contrib.sites create_default_site() when 'default' DATABASES is empty.
2015-02-13 07:01:28 -05:00
Josh Smeaton
bd4afef984
Refs #14030 -- Added tests for Value aggregates
2015-02-13 10:06:46 +11:00
Josh Smeaton
de0241eb98
Fixed #24319 -- Added validation for UUID model field
2015-02-13 09:45:53 +11:00
Tim Graham
d64baaef3b
Fixed #24333 -- Fixed admin history view crash with non-integer slug.
2015-02-12 14:19:44 -05:00
Simon Charette
9239f1dda7
Refs #24215 -- Prevented pending lookup pollution by abstract models.
2015-02-12 13:07:09 -05:00
Tim Graham
d7509c5246
Added a test for UUIDField serialization; refs #24320 .
2015-02-12 09:54:42 -05:00
Tim Graham
e4999bf671
Added missing import from last commit.
2015-02-12 08:18:10 -05:00
Tim Graham
27eeb64a96
Fixed #17716 -- Prevented include('...', app_name='...') without a namespace.
2015-02-12 08:07:58 -05:00
Tim Graham
0f7f5bc9e7
Fixed #24161 -- Stored the user primary key as a serialized value in the session.
...
This allows using a UUIDField primary key along with the JSON session
serializer.
Thanks to Trac alias jamesbeith for the report and Simon Charette
for the initial patch.
2015-02-12 07:38:16 -05:00
Lukas Klein
93b3ef9b2e
Fixed #24321 -- Improved `utils.http.same_origin` compliance with RFC6454
2015-02-12 08:58:35 +01:00
Josh Smeaton
e2d6e14662
Refs #14030 -- Improved expression support for python values
2015-02-12 08:46:25 +11:00
Collin Anderson
07cfe1bd82
Refs #14497 -- Handled empty readonly admin FileFields
2015-02-11 13:00:56 -05:00
Tim Graham
8ec306a3a9
Moved contrib.webdesign tests out of contrib.
2015-02-11 12:30:07 -05:00
Tim Graham
7cf3a5786b
Updated docs and runtests.py for removal of tests from contrib.
2015-02-11 10:29:54 -05:00
Tim Graham
ad0be620ae
Moved contrib.gis tests out of contrib.
2015-02-11 10:29:54 -05:00