summaryrefslogtreecommitdiff
path: root/tests/multiple_database
Commit message (Collapse)AuthorAgeFilesLines
* Fixed #33985 -- Used app_config.verbose_name in ContentType.__str__().Hrushikesh Vaidya2023-03-091-1/+1
|
* Refs #33476 -- Applied Black's 2023 stable style.David Smith2023-02-011-1/+0
| | | | | | | | 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
* Refs #33990 -- Renamed TransactionTestCase.assertQuerysetEqual() to ↵Gregor Gärtner2022-10-081-2/+2
| | | | | | assertQuerySetEqual(). Co-Authored-By: Michael Howitz <mh@gocept.com>
* Removed redundant QuerySet.all() calls in docs and tests.Nick Pope2022-02-221-5/+5
| | | | Most QuerySet methods are mapped onto the Manager and, in general, it isn't necessary to call .all() on the manager.
* Refs #33476 -- Refactored code to strictly match 88 characters line length.Mariusz Felisiak2022-02-071-13/+40
|
* Refs #33476 -- Reformatted code with Black.django-bot2022-02-073-681/+1079
|
* Fixed isolation of RouterTestCase.test_m2m_cross_database_protection().Mariusz Felisiak2021-07-051-2/+2
| | | | | | Hardcoded pks are necessary for this test case, however we need to set them for all new rows because the sequence will not increment automatically. It works when the sequence is incremented by other test cases.
* Removed unused __str__() methods in tests models.Mariusz Felisiak2020-04-301-3/+0
| | | Follow up to 6461583b6cc257d25880ef9a9fd7e2125ac53ce1.
* Enforced uniqueness of natural keys used in tests.Mariusz Felisiak2020-04-071-1/+1
|
* Refs #31117 -- Made various tests properly handle unexpected databases aliases.Matthijs Kooijman2020-01-201-2/+2
| | | | | | | | - Used selected "databases" instead of django.db.connections. - Made routers in tests.migrations skip migrations on unexpected databases. - Added DiscoverRunnerGetDatabasesTests.assertSkippedDatabases() hook which properly asserts messages about skipped databases.
* Fixed #16027 -- Added app_label to ContentType.__str__().Gregory N. Schmit2019-02-071-2/+2
|
* Refs #28478 -- Deprecated TestCase's allow_database_queries and multi_db in ↵Simon Charette2019-01-101-11/+11
| | | | favor of databases.
* Followed style guide for model attribute ordering.Matt Wiens2018-12-271-12/+14
|
* Switched TestCase to SimpleTestCase where possible in Django's tests.Tim Graham2018-11-271-1/+1
|
* Fixed #27629 -- Added router.allow_relation() calls for assignments between ↵Stefan R. Filipek2018-05-101-0/+25
| | | | unsaved model instances.
* Fixed hanging indentation in various code.Mariusz Felisiak2018-03-161-17/+23
|
* Fixed #28982 -- Simplified code with and/or.Дилян Палаузов2018-01-031-3/+1
|
* Fixed #28974 -- Made refresh_from_db() hint routers about its instance.Simon Charette2018-01-021-0/+9
|
* Removed a primary key value dependency in a multiple_database test.Tim Graham2017-07-311-2/+2
| | | | Follow up to a51c4de1945be2225f20fad794cfb52d8f1f9236.
* Used assertRaisesMessage() to test Django's error messages.Mads Jensen2017-07-291-13/+45
|
* Replaced type-specific assertions with assertEqual().Tim Graham2017-03-171-3/+3
| | | Python docs say, "it's usually not necessary to invoke these methods directly."
* Refs #23919 -- Replaced kwargs.pop() with keyword-only arguments.Vytis Banaitis2017-02-011-4/+2
|
* Refs #27790 -- Reverted "Removed available_apps on TestCase subclasses."Tim Graham2017-01-281-0/+6
| | | | | This reverts commit 91023d79ec70df9289271e63a67675ee51e7dea8 as it increases memory usage for the test suite.
* Refs #23919 -- Replaced super(ClassName, self) with super().chillaranand2017-01-251-2/+2
|
* Refs #23919 -- Stopped inheriting from object to define new style classes.Simon Charette2017-01-192-10/+10
|
* Refs #23919 -- Removed most of remaining six usageClaude Paroz2017-01-181-1/+1
| | | | Thanks Tim Graham for the review.
* Refs #23919 -- Removed python_2_unicode_compatible decorator usageClaude Paroz2017-01-181-5/+0
|
* Refs #23919 -- Removed encoding preambles and future importsClaude Paroz2017-01-182-4/+0
|
* Removed available_apps on TestCase subclasses.Simon Charette2017-01-131-5/+0
| | | | | | | TestCase subclasses are wrapped in a transaction that prevents any data from being persisted between test runs andi thus don't require limiting the tables to be flushed to a subset of available apps like TransactionTestCase subclasses do.
* Refs #27392 -- Removed "Tests that", "Ensures that", etc. from test docstrings.za2016-11-101-23/+22
|
* Removed unused lines in multiple_database test.Tim Graham2016-09-071-7/+1
|
* Replaced use of TestCase.fail() with assertRaises().Tim Graham2016-06-281-171/+101
| | | Also removed try/except/fail antipattern that hides exceptions.
* Fixed #26784 -- Made ForeignKey.validate() pass `model` to router if ↵Ben Demboski2016-06-271-0/+11
| | | | model_instance=None.
* Fixed #26747 -- Used more specific assertions in the Django test suite.Jon Dufresne2016-06-161-6/+6
|
* Fixed E128 flake8 warnings in tests/.Tim Graham2016-04-081-118/+62
|
* Refs #26022 -- Used context manager version of assertRaises in tests.Hasan2016-01-291-55/+38
|
* Fixed #25550 -- Deprecated direct assignment to the reverse side of a ↵Tim Graham2015-10-271-16/+17
| | | | related set.
* Refs #24351 -- Removed support for the old allow_migrate() signature per ↵Tim Graham2015-09-231-32/+0
| | | | deprecation timeline.
* Fixed #23395 -- Limited line lengths to 119 characters.Dražen Odobašić2015-09-121-109/+251
|
* Fixed #18556 -- Allowed RelatedManager.add() to execute 1 query where possible.Tim Graham2015-07-281-2/+13
| | | | Thanks Loic Bistuer for review.
* Fixed #21127 -- Started deprecation toward requiring on_delete for ↵Flavio Curella2015-07-271-4/+4
| | | | ForeignKey/OneToOneField
* Renamed RemovedInDjangoXYWarnings for new roadmap.Tim Graham2015-06-241-2/+2
| | | | | Forwardport of ae1d663b7913f6da233c55409c4973248372d302 from stable/1.8.x plus more.
* Refs #24652 -- Used SimpleTestCase where appropriate.Simon Charette2015-05-201-2/+2
|
* Fixed #24714 -- Used more specific assertions than assertEqual in tests.Alasdair Nicol2015-04-281-1/+1
|
* Fixed allow_migrate signature in one of the tests.Loic Bistuer2015-02-211-1/+1
| | | | Refs #24351.
* Fixed #24351, #24346 -- Changed the signature of allow_migrate().Loic Bistuer2015-02-202-31/+65
| | | | | | | | | | | | | | The new signature enables better support for routing RunPython and RunSQL operations, especially w.r.t. reusable and third-party apps. This commit also takes advantage of the deprecation cycle for the old signature to remove the backward incompatibility introduced in #22583; RunPython and RunSQL won't call allow_migrate() when when the router has the old signature. Thanks Aymeric Augustin and Tim Graham for helping shape up the patch. Refs 22583.
* Sorted imports with isort; refs #23860.Tim Graham2015-02-062-3/+3
|
* Removed support for initial_data fixtures per deprecation timeline.Tim Graham2015-01-171-4/+2
|
* Removed an incorrect docstring in tests/multiple_database/tests.py.wrwrwr2014-12-011-1/+0
|
* Removed a no-op statement in tests/multiple_database/tests.py.wrwrwr2014-12-011-2/+0
|