summaryrefslogtreecommitdiff
path: root/tests/invalid_models_tests
Commit message (Collapse)AuthorAgeFilesLines
* Fixed #470 -- Added support for database defaults on fields.Ian Foote2023-05-121-0/+107
| | | | | | | | Special thanks to Hannes Ljungberg for finding multiple implementation gaps. Thanks also to Simon Charette, Adam Johnson, and Mariusz Felisiak for reviews.
* Refs #31369 -- Improved hint message in NullBooleanField's deprecation warning.Paul Brown2023-05-021-1/+1
|
* Refs #33476 -- Applied Black's 2023 stable style.David Smith2023-02-012-1/+1
| | | | | | | | Black 23.1.0 is released which, as the first release of the year, introduces the 2023 stable style. This incorporates most of last year's preview style. https://github.com/psf/black/releases/tag/23.1.0
* Fixed #14094 -- Added support for unlimited CharField on PostgreSQL.Adrian Torres2022-12-281-4/+6
| | | | Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
* Fixed #18468 -- Added support for comments on columns and tables.kimsoungryoul2022-12-283-1/+71
| | | | | | | | Thanks Jared Chung, Tom Carrick, David Smith, Nick Pope, and Mariusz Felisiak for reviews. Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com> Co-authored-by: Nick Pope <nick@nickpope.me.uk>
* Fixed #33872 -- Deprecated ↵Mariusz Felisiak2022-08-031-0/+62
| | | | django.contrib.postgres.fields.CIText/CICharField/CIEmailField/CITextField.
* Fixed #27236 -- Deprecated Meta.index_together in favor of Meta.indexes.David Wobrock2022-07-121-1/+3
| | | | This also deprecates AlterIndexTogether migration operation.
* Fixed #30581 -- Added support for Meta.constraints validation.Gagaro2022-05-101-0/+60
| | | | Thanks Simon Charette, Keryn Knight, and Mariusz Felisiak for reviews.
* Refs #33476 -- Refactored code to strictly match 88 characters line length.Mariusz Felisiak2022-02-074-24/+68
|
* Refs #33476 -- Reformatted code with Black.django-bot2022-02-076-2545/+3244
|
* Refs #33476 -- Refactored problematic code before reformatting by Black.Mariusz Felisiak2022-02-031-12/+6
| | | | | | | | | | | | | | | | | In these cases Black produces unexpected results, e.g. def make_random_password( self, length=10, allowed_chars='abcdefghjkmnpqrstuvwxyz' 'ABCDEFGHJKLMNPQRSTUVWXYZ' '23456789', ): or cursor.execute(""" SELECT ... """, [table name], )
* Fixed #33131 -- Improved error messages for clashing reverse accessor names.Bernd Wechner2021-10-061-52/+57
|
* Fixed #33084 -- Removed incorrect system check for ManyToManyField with ↵Hasan Ramezani2021-09-091-27/+1
| | | | limit_choices_to.
* Fixed #32983 -- Added system check for redundant related_name on symmetrical ↵Nick Touran2021-08-061-0/+14
| | | | | | | | | | | M2M fields. Since ManyToManyFields defined with `symmetrical=True` do not add a related field to the target model, including a `related_name` argument will never do what the coder likely expects. This makes including a related_name with a symmetrical model raise a system check warning. ticket-32983
* Fixed #32966 -- Fixed TimeField.check() crash for timezone-aware times in ↵Chris Jerdonek2021-07-301-9/+23
| | | | default when USE_TZ = True.
* Fixed #32947 -- Fixed hash() crash on reverse M2M relation when ↵Tom Wojcik2021-07-261-0/+27
| | | | | | through_fields is a list. Regression in c32d8f33d8e988a376e44997b8f3606d821f305e.
* Refs #32508 -- Raised Type/ValueError instead of using "assert" in ↵Daniyal2021-07-151-0/+12
| | | | | | django.db.models. Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
* Fixed #30427, Fixed #16176 -- Corrected setting descriptor in ↵Carlton Gibson2021-06-151-3/+2
| | | | | | Field.contribute_to_class(). Co-authored-by: Jarek Glowacki <jarekwg@gmail.com>
* Fixed #32635 -- Fixed system check crash for reverse o2o relations in ↵Hasan Ramezani2021-04-141-0/+43
| | | | | | | | CheckConstraint.check and UniqueConstraint.condition. Regression in b7b7df5fbcf44e6598396905136cab5a19e9faff. Thanks Szymon Zmilczak for the report.
* Refs #31530 -- Added test for joined OneToOneField in CheckConstraint.checkHasan Ramezani2021-04-141-1/+11
|
* Fixed #30916 -- Added support for functional unique constraints.Hannes Ljungberg2021-02-231-0/+141
| | | | Thanks Ian Foote and Mariusz Felisiak for reviews.
* Refs #12990 -- Removed django.contrib.postgres.fields.JSONField per ↵Mariusz Felisiak2021-01-141-1/+20
| | | | deprecation timeline.
* Refs #31369 -- Removed models.NullBooleanField per deprecation timeline.Mariusz Felisiak2021-01-141-4/+4
|
* Fixed #32321 -- Added system checks for invalid model field names in ↵Hasan Ramezani2021-01-141-1/+94
| | | | functional indexes.
* Fixed #26167 -- Added support for functional indexes.Hannes Ljungberg2021-01-131-0/+30
| | | | | | Thanks Simon Charette, Mads Jensen, and Mariusz Felisiak for reviews. Co-authored-by: Markus Holtermann <info@markusholtermann.eu>
* Fixed #32294 -- Prevented ManyToManyField's hidden related name collisions ↵manav0142020-12-301-1/+27
| | | | between apps.
* Added app labels to related fields checks messages E302-E305.Mariusz Felisiak2020-12-291-92/+193
|
* Fixed #31777 -- Added support for database collations to Char/TextFields.Tom Carrick2020-09-211-1/+49
| | | | Thanks Simon Charette and Mariusz Felisiak for reviews.
* Fixed #31530 -- Added system checks for invalid model field names in ↵Hasan Ramezani2020-07-061-0/+232
| | | | CheckConstraint.check and UniqueConstraint.condition.
* Refs #30913 -- Added system checks for covering indexes and unique ↵Mariusz Felisiak2020-06-041-0/+96
| | | | constraints support.
* Fixed #30913 -- Added support for covering indexes on PostgreSQL 11+.Hannes Ljungberg2020-06-041-0/+159
|
* Fixed #31410 -- Added system checks for invalid model field names in ↵Hasan Ramezani2020-05-201-0/+67
| | | | UniqueConstraint.
* Fixed #12990, Refs #27694 -- Added JSONField model field.sage2020-05-082-2/+82
| | | | | | | | | | | 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>
* Fixed #31538 -- Fixed Meta.ordering validation lookups that are not transforms.Mariusz Felisiak2020-05-051-0/+9
| | | | | Regression in 440505cb2cadbe1a5b9fba246bcde6c04f51d07e. Thanks Simon Meers for the report.
* Fixed #20581 -- Added support for deferrable unique constraints.Ian Foote2020-04-301-0/+44
|
* Refs #31369 -- Deprecated models.NullBooleanField in favor of ↵Tim Schilling2020-04-241-0/+15
| | | | BooleanField(null=True).
* Fixed #31351 -- Added system checks for partial indexes and unique ↵Ichlasul Affan2020-04-101-1/+88
| | | | constraints support.
* Refs #31055 -- Allowed database queries in ↵Mariusz Felisiak2020-04-101-1/+2
| | | | invalid_models_tests.test_models.FieldNamesTests.
* Fixed #31144 -- Relaxed system check for max_length of CharFields on ↵Rohit2020-03-201-3/+8
| | | | MySQL/MariaDB by turning into a warning.
* Refs #29548 -- Mentioned MariaDB in database system checks.Mariusz Felisiak2020-03-191-1/+2
|
* Removed redundant get_max_column_name_length() calls in ↵Mariusz Felisiak2020-03-181-4/+0
| | | | invalid_models_tests.test_models.FieldNamesTests.
* Refs #31055 -- Made long column names checks support databases aware.Mariusz Felisiak2020-03-181-4/+9
|
* Fixed #31310 -- Fixed hints in checks for using intermediate model with ↵Matheus Cunha Motta2020-02-281-4/+3
| | | | | | | ambiguous foreign key. symmetrical=False is not required since 87b1ad6e7351464c60e751b483d9dfce3a2d3382.
* Refs #31310 -- Added test for check for using intermediate model with ↵Matheus Cunha Motta2020-02-281-0/+30
| | | | ambiguous foreign key from model.
* Fixed #31185 -- Fixed detecting of unique fields in ForeignKey/ForeignObject ↵Valze2020-02-271-8/+136
| | | | checks when using Meta.constraints.
* Fixed #31286 -- Made database specific fields checks databases aware.Taoup2020-02-242-2/+2
| | | | Follow up to 0b83c8cc4db95812f1e15ca19d78614e94cf38dd.
* Fixed #31277 -- Relaxed system check of m2m intermediary tables for db_table ↵Xavier Francisco2020-02-171-0/+83
| | | | | | collision when database routers are installed. Turned the error into a warning when database routers are installed.
* Refs #31055 -- Fixed Model.check() call in ↵Mariusz Felisiak2020-02-081-1/+1
| | | | ConstraintsTests.test_check_constraints_required_db_features().
* Fixed #31055 -- Made constraint checks support databases aware.Simon Charette2020-02-071-4/+4
|
* Simplified imports from django.db and django.contrib.gis.db.Nick Pope2020-02-041-5/+4
|