summaryrefslogtreecommitdiff
path: root/tests/modeltests/model_forms
AgeCommit message (Collapse)Author
2013-02-26Merged regressiontests and modeltests into the test root.Florian Apolloner
2013-02-23Fixed #18829 -- Fixed ModelChoiceIterator lengthKlaas van Schelven
Thanks facundo.olano at gmail.com for the report and thikonom for the initial patch.
2013-02-23Fixed #15877 -- Improved exception when ModelForm has no model classClaude Paroz
Thanks theaspect at gmail.com for the report and volrath for the patch.
2013-02-23Fixed #19686 -- Added HTML5 number input typeClaude Paroz
Thanks Simon Charette for his help on the patch. Refs #16630.
2012-12-29Fixed autopk issue in testsAnssi Kääriäinen
2012-12-19Fixed #18172 -- Made models with __iter__ usable in ModelMultipleChoiceFieldPatryk Zawadzki
Thanks to Patryk Zawadzki for the patch.
2012-12-13Fixed #19462 -- Made assertQuerysetEqual detect undefined orderingAnssi Kääriäinen
If there are more than one values to compare against and the qs isn't ordered then assertQuerysetEqual will raise a ValueError.
2012-12-08Removed US localflavor-specific tests from coreClaude Paroz
Also fixes #9045.
2012-12-08Fixed #19357 -- Allow non-ASCII chars in filesystem pathsClaude Paroz
Thanks kujiu for the report and Aymeric Augustin for the review.
2012-11-04Fixed #18949 -- Fix broken test interactions in ModelForms testsAnton I. Sipos
A test in Model Forms test was specifically referring to a fixed primary key, which was now being used up in a newly committed. This has been worked around by specifying a higher primary key.
2012-11-04Fixed #18949 -- Improve performance of model_to_dict with many-to-manyAnton I. Sipos
When calling model_to_dict, improve performance of the generated SQL by using values_list to determine primary keys of many to many objects. Add a specific test for this function, test_model_to_dict_many_to_many Thanks to brian for the original report and suggested fix.
2012-10-03Fixed #14567 -- Made ModelMultipleChoiceField return EmptyQuerySet as empty ↵Stephen Burrows
value
2012-08-14[py3] Fixed modeltests.model_forms tests.Chris Lawlor
2012-08-12[py3] Refactored __unicode__ to __str__.Aymeric Augustin
* Renamed the __unicode__ methods * Applied the python_2_unicode_compatible decorator * Removed the StrAndUnicode mix-in that is superseded by python_2_unicode_compatible * Kept the __unicode__ methods in classes that specifically test it under Python 2
2012-08-04Fixed #5524 -- Do not remove cleaned_data when a form fails validationClaude Paroz
cleaned_data is no longer deleted when form validation fails but only contains the data that did validate. Thanks to the various contributors to this patch (see ticket).
2012-07-22[py3] Replaced unicode/str by six.text_type/bytes.Aymeric Augustin
2012-06-07Fixed #18269 -- Applied unicode_literals for Python 3 compatibility.Claude Paroz
Thanks Vinay Sajip for the support of his django3 branch and Jannis Leidel for the review.
2012-05-19Marked bytestrings with b prefix. Refs #18269Claude Paroz
This is a preparation for unicode literals general usage in Django (Python 3 compatibility).
2012-05-05Replaced cStringIO.StringIO by io.BytesIO.Claude Paroz
Also replaced StringIO.StringIO by BytesIO in some other appropriate places. StringIO is not available in Python 3.
2012-05-05Made more extensive usage of context managers with open.Claude Paroz
2012-03-30Removed with_statement imports, useless in Python >= 2.6. Refs #17965. ↵Claude Paroz
Thanks jonash for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@17828 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2012-03-29Fixed #11150 -- Removed dependency on cStringIO in ImageField validation. ↵Claude Paroz
Thanks vvd for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@17825 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2012-01-31Fixed #16921 -- Added assertHTMLEqual and assertHTMLNotEqual assertions, and ↵Carl Meyer
converted Django tests to use them where appropriate. Thanks Greg Müllegger. git-svn-id: http://code.djangoproject.com/svn/django/trunk@17414 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-13Refs #17215: Avoid generating 47 leftover tmp dirs during a clean test run.Karen Tracey
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17094 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13Convert all modeltests to use absolute imports, rather than relative ones.Alex Gaynor
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16975 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-30Fixed #16645: fixed a broken test to work in Oracle.Ian Kelly
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16919 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-21Fixed #16644 -- Fixed one additional test that was failing in Oracle due to ↵Ramiro Morales
false assumptions about the primary keys of objects. Thanks Aymeric Augustin for report and patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16636 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-07-13Fixed #16225 -- Removed unused imports. Many thanks to Aymeric Augustin for ↵Jannis Leidel
the work on the patch and Alex for reviewing. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16539 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-06-13Fixed #16243 -- Corrected test suite failure in model_forms when PIL isn't ↵Russell Keith-Magee
installed git-svn-id: http://code.djangoproject.com/svn/django/trunk@16391 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-06-10Fixed #16210 -- Added some missing __future__ imports to support with ↵Russell Keith-Magee
statements on 2.5. Thanks to Julien Phalip for the report and patch git-svn-id: http://code.djangoproject.com/svn/django/trunk@16359 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-06-10Fixed #16198 -- Ported the model_forms doctests. Our long national nightmare ↵Russell Keith-Magee
is over. Oh, and we have always been at war with doctests. Thanks to Peter van Kampen and Gregor Müllegger for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16358 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-04-22Fixed #6953 -- Correctly sort ManyToMany fields in ModelForms. Thanks, ↵Jannis Leidel
dgouldin, mk and Alex. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16063 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-03-09Fixed a bunch more tests that were failing in Oracle due to false ↵Ian Kelly
assumptions about the primary keys of objects. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15789 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-03-04Refs #15550 -- Corrected another primary-key ordering problem in the ↵Russell Keith-Magee
modelforms tests. Thanks to bberes for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15753 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-03-04Fixed #15550 -- Corrected an ordering dependency in the model_forms ↵Russell Keith-Magee
doctests. Thanks to bberes for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15745 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-26Revert [15653], which was absolutely not ready to be committed.Alex Gaynor
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15655 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-26Beginnings of test conversion.Alex Gaynor
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15653 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-19Fixed #9161 -- Ensure that ModelMultipleChoiceField respects to_field_name ↵Russell Keith-Magee
in validation. Thanks to Honza for the report, and Gregor Müllegger for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15587 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-09Fixed #14951 -- Made the unique_for_{date,month,year} model field ↵Ramiro Morales
constraints to not fail when the related DateField is empty. Existing modelforms tests were extended to cover this case and an equivalent set of tests was added for the model functionality. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15167 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-11-11Removed the executable bit from a test file, it wasn't. Thanks to Florian ↵Alex Gaynor
for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14530 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-08-17Fixed #14102 -- Ensure that fields that have been excluded from a form ↵Russell Keith-Magee
aren't included in the unique_for_* checks, either. Thanks to Travis Cline for the report and fix. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13598 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-08-06Fixed #8426 - added 'helptext' CSS class to help text in forms to aid in stylingLuke Plant
Thanks to erikcw for report, mrts and rpbarlow for patch git-svn-id: http://code.djangoproject.com/svn/django/trunk@13519 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-04-21Fixed the model_forms doctests to not depend on writer PKs, which are ↵Karen Tracey
db-dependent after r12797. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13015 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-31Restored pre-r10062 behavior allowing None from formfield_callback to ↵Brian Rosner
exclude itself from the form git-svn-id: http://code.djangoproject.com/svn/django/trunk@12891 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-18Fixed #13138: Ensure required=False on a model form field overrides Karen Tracey
blank=False on the underlying model field during model form clean, in order to maintain backward compatibility. Thanks to saxon75 for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12802 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-16Fixed #12881: Corrected handling of inherited unique constraints. Thanks for ↵Karen Tracey
report fgaudin. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12797 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-25Fixed #12901. Again. Model validation will not be performed on excluded ↵Joseph Kocherhans
fields that were overridden in the form. Thanks, ammarr. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12590 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-22Fixed #12901. Exclude overridden form fields from model field validation. ↵Joseph Kocherhans
Thanks, Honza Král. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12496 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-14Fixed #6054: work around PIL's installation brokeness by detecting either of ↵Jacob Kaplan-Moss
the two ways it can end up being installed. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12429 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-01-12Fixed #12512. Changed ModelForm to stop performing model validation on ↵Joseph Kocherhans
fields that are not part of the form. Thanks, Honza Kral and Ivan Sagalaev. This reverts some admin and test changes from [12098] and also fixes #12507, #12520, #12552 and #12553. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12206 bcc190cf-cafb-0310-a4f2-bffc1f526a37