summaryrefslogtreecommitdiff
path: root/tests/invalid_models_tests
AgeCommit message (Collapse)Author
2021-01-14Fixed #32321 -- Added system checks for invalid model field names in ↵Hasan Ramezani
functional indexes.
2021-01-13Fixed #26167 -- Added support for functional indexes.Hannes Ljungberg
Thanks Simon Charette, Mads Jensen, and Mariusz Felisiak for reviews. Co-authored-by: Markus Holtermann <info@markusholtermann.eu>
2020-12-30Fixed #32294 -- Prevented ManyToManyField's hidden related name collisions ↵manav014
between apps.
2020-12-29Added app labels to related fields checks messages E302-E305.Mariusz Felisiak
2020-09-21Fixed #31777 -- Added support for database collations to Char/TextFields.Tom Carrick
Thanks Simon Charette and Mariusz Felisiak for reviews.
2020-07-06Fixed #31530 -- Added system checks for invalid model field names in ↵Hasan Ramezani
CheckConstraint.check and UniqueConstraint.condition.
2020-06-04Refs #30913 -- Added system checks for covering indexes and unique ↵Mariusz Felisiak
constraints support.
2020-06-04Fixed #30913 -- Added support for covering indexes on PostgreSQL 11+.Hannes Ljungberg
2020-05-20Fixed #31410 -- Added system checks for invalid model field names in ↵Hasan Ramezani
UniqueConstraint.
2020-05-08Fixed #12990, Refs #27694 -- Added JSONField model field.sage
Thanks to Adam Johnson, Carlton Gibson, Mariusz Felisiak, and Raphael Michel for mentoring this Google Summer of Code 2019 project and everyone else who helped with the patch. Special thanks to Mads Jensen, Nick Pope, and Simon Charette for extensive reviews. Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-05-05Fixed #31538 -- Fixed Meta.ordering validation lookups that are not transforms.Mariusz Felisiak
Regression in 440505cb2cadbe1a5b9fba246bcde6c04f51d07e. Thanks Simon Meers for the report.
2020-04-30Fixed #20581 -- Added support for deferrable unique constraints.Ian Foote
2020-04-24Refs #31369 -- Deprecated models.NullBooleanField in favor of ↵Tim Schilling
BooleanField(null=True).
2020-04-10Fixed #31351 -- Added system checks for partial indexes and unique ↵Ichlasul Affan
constraints support.
2020-04-10Refs #31055 -- Allowed database queries in ↵Mariusz Felisiak
invalid_models_tests.test_models.FieldNamesTests.
2020-03-20Fixed #31144 -- Relaxed system check for max_length of CharFields on ↵Rohit
MySQL/MariaDB by turning into a warning.
2020-03-19Refs #29548 -- Mentioned MariaDB in database system checks.Mariusz Felisiak
2020-03-18Removed redundant get_max_column_name_length() calls in ↵Mariusz Felisiak
invalid_models_tests.test_models.FieldNamesTests.
2020-03-18Refs #31055 -- Made long column names checks support databases aware.Mariusz Felisiak
2020-02-28Fixed #31310 -- Fixed hints in checks for using intermediate model with ↵Matheus Cunha Motta
ambiguous foreign key. symmetrical=False is not required since 87b1ad6e7351464c60e751b483d9dfce3a2d3382.
2020-02-28Refs #31310 -- Added test for check for using intermediate model with ↵Matheus Cunha Motta
ambiguous foreign key from model.
2020-02-27Fixed #31185 -- Fixed detecting of unique fields in ForeignKey/ForeignObject ↵Valze
checks when using Meta.constraints.
2020-02-24Fixed #31286 -- Made database specific fields checks databases aware.Taoup
Follow up to 0b83c8cc4db95812f1e15ca19d78614e94cf38dd.
2020-02-17Fixed #31277 -- Relaxed system check of m2m intermediary tables for db_table ↵Xavier Francisco
collision when database routers are installed. Turned the error into a warning when database routers are installed.
2020-02-08Refs #31055 -- Fixed Model.check() call in ↵Mariusz Felisiak
ConstraintsTests.test_check_constraints_required_db_features().
2020-02-07Fixed #31055 -- Made constraint checks support databases aware.Simon Charette
2020-02-04Simplified imports from django.db and django.contrib.gis.db.Nick Pope
2020-01-16Fixed #29998 -- Allowed multiple OneToOneFields to the parent model.Mariusz Felisiak
We assumed that any OneToOneField's in a child model must be the parent link and raised an error when parent_link=True was not specified. This patch allows to specify multiple OneToOneField's to the parent model. OneToOneField's without a custom related_name will raise fields.E304 and fields.E305 so this should warn users when they try to override the auto-created OneToOneField.
2020-01-11Fixed #31155 -- Fixed a system check for the longest choice when a named ↵Mariusz Felisiak
group contains only non-string values. Regression in b6251956b69512bf230322bd7a49b629ca8455c6. Thanks Murat Guchetl for the report.
2019-11-19Fixed #30987 -- Added models.PositiveBigIntegerField.Caio Ariede
2019-09-27Fixed #30798 -- Fixed Meta.ordering validation for pk of related fields.Hasan Ramezani
Regression in 440505cb2cadbe1a5b9fba246bcde6c04f51d07e.
2019-09-27Refs #30798 -- Prevented chaining fields from the same related model ↵Hasan Ramezani
multiple times in model Meta.ordering.
2019-09-09Fixed #30757 -- Added a system check to ensure max_length fits the longest ↵Nick Pope
choice.
2019-08-20Fixed #29979, Refs #17337 -- Extracted AutoField field logic into a mixin ↵Nick Pope
and refactored AutoFields. This reduces duplication by allowing AutoField, BigAutoField and SmallAutoField to inherit from IntegerField, BigIntegerField and SmallIntegerField respectively. Doing so also allows for enabling the max_length warning check and minimum/maximum value validation for auto fields, as well as providing a mixin that can be used for other possible future auto field types such as a theoretical UUIDAutoField.
2019-08-12Refs #11964 -- Made constraint support check respect required_db_features.Simon Charette
This will notably silence the warnings issued when running the test suite on MySQL.
2019-07-05Fixed #30613 -- Moved index name validation to system checks.can
2019-06-21Fixed #30421 -- Allowed symmetrical intermediate table for self-referential ↵Nadège Michel
ManyToManyField.
2019-05-01Fixed #30409 -- Allowed using foreign key's attnames in ↵zeyneloz
unique/index_together and Index's fields.
2019-04-18Fixed #30367 -- Changed "pip install" to "python -m pip install" in docs, ↵Ramiro Morales
comments and hints.
2019-03-25Fixed #28431 -- Added a system check for BinaryField to prevent strings ↵Hasan Ramezani
defaults. Thanks Claude Paroz for the initial patch.
2019-03-01Refs #29408 -- Cosmetic edits for validation of related fields and lookups ↵Mariusz Felisiak
in model Meta.ordering. Follow up to 440505cb2cadbe1a5b9fba246bcde6c04f51d07e.
2019-03-01Fixed #29408 -- Added validation of related fields and lookups in model ↵Hasan Ramezani
Meta.ordering.
2019-02-09Removed uneeded generator expressions and list comprehensions.Sergey Fedoseev
2019-01-14Refs #28478 -- Prevented database feature based skipping on tests ↵Simon Charette
disallowing queries. Database features may require a connection to be established to determine whether or not they are enabled.
2018-11-27Switched TestCase to SimpleTestCase where possible in Django's tests.Tim Graham
2018-11-23Refs #23801 -- Made integer field max_length warning show correct field type.Nick Pope
2018-11-17Added test for Model._check_column_name_clashes().Hasan Ramezani
2018-10-02Refs #11964 -- Changed CheckConstraint() signature to use keyword-only ↵Simon Charette
arguments. Also renamed the `constraint` argument to `check` to better represent which part of the constraint the provided `Q` object represents.
2018-08-22Fixed #26352 -- Made system check allow ManyToManyField to target the same ↵Simon Willison
model if through_fields differs.
2018-08-22Fixed #29698 -- Fixed Field._check_choices() crash on invalid choices.Franck Michea