summaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)Author
2008-10-06Added some better error reporting and path handling when creating template ↵Malcolm Tredinnick
paths. We now raise UnicodeDecodeError for non-UTF-8 bytestrings (thanks to Daniel Pope for diagnosing this was being swallowed by ValueError) and allow UTF-8 bytestrings as template directories. Refs #8965. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9161 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-10-05Fixed #9259 -- Fixed a validation error for Spanish identity card numbers.Malcolm Tredinnick
Patch from Marc Garcia. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9129 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-10-05Add internationalisation support to the comment templates. Fixed #8868, #8905Malcolm Tredinnick
Thanks to zgoda for a patch that did most of the internationalisation part. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9119 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-10-05Fixed #8803 -- Allow authenticated users without first_name/last_name values ↵Malcolm Tredinnick
set to post comments. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9118 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-10-05Altered a failing url template tag test to work more reliably.Malcolm Tredinnick
There's no guarantee about the order in which ambiguous patterns are resolved. The solution is "don't do that" and avoid ambiguity. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9113 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-10-04Fixed #9293: Corrected expected test output for the admin_scripts tests, ↵Russell Keith-Magee
following the changes to --verbosity in 9110. Thanks to Alex for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9112 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-10-02Promoted --verbosity to be a top level option for all management commands. ↵Russell Keith-Magee
Also added -v as a consistent short form of --verbosity. This is mostly to save Malcolm's poor arthritic fingers. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9110 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-30Fixed another case of reverse URL resolving that wasn't working.Malcolm Tredinnick
This is a similar situation to that fixed in r9087. We weren't merging multiple levels of include() calls together correctly. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9099 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-28Fixed Queryset.dates() in the presence of extra-select columns.Malcolm Tredinnick
Any extra(select=...) columns can be ignored in the SQL for dates, since we are only interested in extracting distinct date values. We were previously including them by accident and it was generating incorrect SQL. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9091 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-27Fixed #9038 -- Correctly handle URL patterns with the same name (or view name),Malcolm Tredinnick
declared independently and that differ only by argument signatures. Patch from Russell Keith-Magee. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9087 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-27Fixed #9171 -- Fixed a few places where we were assuming lists instead ofMalcolm Tredinnick
generic sequences in ModelForm structures. Patch from mrmachine. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9086 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-22Fixed a missing variable initialisation deep in the Query bowels.Malcolm Tredinnick
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9081 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-18Fixed #9125 -- When displaying errors for a form with only hidden fields, ↵Malcolm Tredinnick
make sure the resulting XHTML is correct. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9067 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-17Fixed #8865 -- Improved the robustness of some file path tests.Malcolm Tredinnick
Based on a patch from pythonhead@gentoo.org. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9065 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-16Fixed #9073 -- Fixed a unit test that broke after [9002]. Thanks, kratoriusAdrian Holovaty
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9046 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-11A bug from queryset-refactor days: although the Query class has "group_by" andMalcolm Tredinnick
"having" attributes, only the former was included in the resulting SQL, meaning subclasses had to completely duplicate Query.as_sql() if they were using any kind of grouping filtering on the results. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9007 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-03Fixed #7588 -- Inherit fields from concrete ancestor classes via abstract baseMalcolm Tredinnick
classes. Based on a patch from emulbreh. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8932 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-03Changed the tests added in r8898 very slightly so that they don't returnMalcolm Tredinnick
unintended results. Doctests aren't self-contained yet when run as part of the full suite. Refs #5624, #8835. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8930 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-03Fixed #8825 -- Fixed a small error model field setup (on the model class) fromMalcolm Tredinnick
r8855. Patch from Christofer Bernander. Test based on one from cgrady. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8908 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-03Fixed #8819 -- Don't include two copies of extra-select columns in the query.Malcolm Tredinnick
This was triggered by r8794, but was, in fact, fairly fragile before then. The current fix is the correct way we should be doing this. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8898 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-03Fixed #8669 -- Use a consistent version of create() across the board forMalcolm Tredinnick
model/field instance creation. Based on a patch from Richard Davies. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8884 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Security fix. Announcement forthcoming.Jacob Kaplan-Moss
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8877 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #7973 -- Added exclude to BaseModelAdmin to make everything consistent ↵Brian Rosner
with the form/formset factories. Refs #8071 to make it easier to get at exclude. Thanks julien for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8861 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #8309: subclasses now inherit `GenericForeignKey` correctly. There's ↵Jacob Kaplan-Moss
also now an internal API so that other "virtual fields" like GFK can be inherited as well. Thanks, msaelices. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8855 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #8795: unique_together validation no longer fails on model forms that ↵Jacob Kaplan-Moss
exclude fields included in the check. Thanks, Alex Gaynor. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8854 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #7154 -- Inherit all model managers from abstract base classes.Malcolm Tredinnick
Also added documentation describing how manager inheritance works (and when manager aren't inherited). Based on some patches from sebastian_noack and emulbreh. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8851 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #8787 -- Fixed failing admin_widgets tests. This fixes ↵Brian Rosner
ManyToManyRawIdWidget which was broken with [8823]. Thanks Alex Gaynor. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8846 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #8196 -- Make the model_form tests also pass if you don't have PILMalcolm Tredinnick
installed. We weren't relying on PIL previously, but the output was different if it wasn't installed, which was triggering spurious failures. Patch from Marty Alchin. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8842 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-02Fixed #8439 -- Complex combinations of Q-objects (using both conjunctions andMalcolm Tredinnick
disjunctions) were producing incorrect SQL when nullable relations were involved. This fixes that. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8832 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed a case of incorrect parsing of quanitifers in reg-exp patterns.Malcolm Tredinnick
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8825 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8648 -- Admin no longer ignores to_field. Thanks for the help Karen ↵Brian Rosner
Tracey and SmileyChris. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8823 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8770: made some tests more robust under MySQL. Thanks, Alex Gaynor.Jacob Kaplan-Moss
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8821 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8210 and #8664: moved `USStateField` and `PhoneNumberField` to ↵Jacob Kaplan-Moss
`django.contrib.localflavor.us`. This is a backwards-incompatible change, albeit a minor one; just add an aditional `import` and go on your way. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8819 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #7975 -- Callable defaults in inline model formsets now work ↵Brian Rosner
correctly. Based on patch from msaelices. Thanks for your hard work msaelices. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8816 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8763: added an explicit ordering to the generic_relations test so ↵Jacob Kaplan-Moss
that the test results aren't dependant on database ordering. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8815 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8076: fixed `get_(next/previous)_by_date` when used with subclasses. ↵Jacob Kaplan-Moss
Thanks, bjornkri and jan_oberst. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8814 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Repaired an oversight from [8772] that let made certain types of fields with ↵Jacob Kaplan-Moss
choices fail. Fixes #6967 again. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8806 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8209: `ModelForm`s now validate unique constraints. Alex Gaynor did ↵Jacob Kaplan-Moss
much of this work, and Brian Rosner helped as well. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8805 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8354: the MySQL backend no longer raises a cryptic error. Instead, it ↵Jacob Kaplan-Moss
raises a less-cryptic error. Obiously this isn't a perfect solution by any means, but it'll do until we can revisit timezone handling in the future. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8802 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Revert [8799]. That wasn't ready for prime-time yet -- thanks, git-svn!Jacob Kaplan-Moss
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8801 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01A failing test for #8354Jacob Kaplan-Moss
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8799 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #7302: Corrected quoting of columns in extra_group_by. Thanks to Ivan ↵Russell Keith-Magee
Sagalaev for the patch and initial test. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8794 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #7512 -- Fixed an oversight when I first fixed ordering on nullableMalcolm Tredinnick
foreign keys (r7761). Thanks to George Vilches for the test case here. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8783 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-09-01Fixed #8316 -- Put tighter restrictions on the type of Foreign Key fieldsMalcolm Tredinnick
created for MySQL (because MySQL + InnoDB has those restrictions). Patch from julianb. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8782 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-31Fixed #8726 -- When doing reverse URL resolving, make sure we're consistentlyMalcolm Tredinnick
dealing with unicode strings throughout by promoting up from UTF-8 as necessary. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8777 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-31Enforce max_num=1 on inline model formsets that have a unique foreign key to ↵Brian Rosner
its parent. I snuck in a quick clean up to the inlineformset_factory as well. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8775 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-31Fixed #6967: `ModelForm`s now validate choices. Thanks, mattmcc -- the ↵Jacob Kaplan-Moss
failing test helped quite a bit. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8772 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-31Added a `TypedChoiceField` which acts just like `ChoiceField`, except that itJacob Kaplan-Moss
returns a value coerced by some provided function. Refs #6967. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8771 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-31Fixed #7027: template tags now corectly break tokens around strings marked ↵Jacob Kaplan-Moss
for translation. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8769 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-31Added a couple of extra tests to ensure url tag robustness. These are anMalcolm Tredinnick
attempt to verify #8726. Refs #8726. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8766 bcc190cf-cafb-0310-a4f2-bffc1f526a37