summaryrefslogtreecommitdiff
path: root/tests/admin_scripts/tests.py
AgeCommit message (Collapse)Author
2017-05-10[1.11.x] Fixed db backend discovery in admin_scripts tests.Florian Apolloner
Not all backends have dots in them. Backport of 60f51290766dae16abfb60459940de51fa5c5b2f from master
2016-12-23Fixed #27626 -- Moved MEDIA_URL/STATIC_URL validation to a system check.Adam Chainz
2016-11-10Refs #27392 -- Removed "Tests that", "Ensures that", etc. from test docstrings.za
2016-11-10Fixed #27438 -- Added the diffsettings --default option.Paweł Marczewski
2016-09-17Refs #27025 -- Fixed "invalid escape sequence" warnings in Python 3.6.Tim Graham
http://bugs.python.org/issue27364
2016-09-16Refs #27025 -- Fixed tests for the new ModuleNotFoundError in Python 3.6.Tim Graham
http://bugs.python.org/issue15767
2016-09-03Fixed #27171 -- Added unicode_literals and coding preamble to all files in ↵Ivan
startapp template on Python 2.
2016-06-23Fixed #26791 -- Replaced LiveServerTestCase port ranges with binding to port 0.Tim Graham
2016-04-08Fixed E128 flake8 warnings in tests/.Tim Graham
2016-03-05Fixed #26315 -- Allowed call_command() to accept a Command object as the ↵Jon Dufresne
first argument.
2016-03-05Cleaned up tests to use call_command() instead of Command.execute().Jon Dufresne
2016-02-12Fixed #25304 -- Allowed management commands to check if migrations are applied.Mounir Messelmeni
2016-01-25Fixed #25968 -- Changed project/app templates to use a "py-tpl" suffix.Chris Lamb
Debian packages unconditionally byte-compile .py files on installation and do not silence errors by design. Therefore, we need a way of shipping these invalid .py files without a .py extension but ensuring that when we template them, they end up as .py. We don't special-case .py files so that the all the TemplateCommand command-line options (eg. extra_files and extensions) still work entirely as expected and it may even be useful for other formats too.
2015-12-21Fixed #25855 -- Enhanced the migration warning for runserver.Emre Yilmaz
Added unapplied migration count and the list of unmigrated apps.
2015-12-12Fixed #25909 -- Added unicode_literals import to apps.py generated by startapp.Tim Graham
2015-10-22Refs #25589 -- Fixed admin_scripts test failure on Windows.Tim Graham
Traceback (most recent call last): File "tests\admin_scripts\tests.py", line 646, in test_startapp_unicode_name content = f.read() File "lib\encodings\cp1252.py", line 23, in decode return codecs.charmap_decode(input,self.errors,decoding_table)[0] UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 46: character maps to <undefined>
2015-10-22Fixed #25589 -- Allowed startapp/project to create apps with Unicode ↵Yoong Kang Lim
characters in the name.
2015-09-12Fixed #23395 -- Limited line lengths to 119 characters.Dražen Odobašić
2015-09-09Supported running admin_script testcases concurrently.Aymeric Augustin
2015-09-07Fixed #24857 -- Added "python -m django" entry point.Ryan Hiebert
2015-09-07Fixed #25356 -- Removed default_app_config from startapp template.Tim Graham
Also discouraged its use outside the intended use case.
2015-09-03Removed some test settings following removal of compatibility checks.Tim Graham
2015-08-31Fixed #25331 -- Removed trailing blank lines in docstrings.Maxime Lorant
2015-08-19Fixed #25285 -- Provided unknown command message with plain django-admin.pyClaude Paroz
Thanks Maxime Lorant for the report and Tim Graham for suggesting the improved comment.
2015-06-16Fixed #24971 -- Made startapp generate an apps.pyMounir Messelmeni
2015-06-11Fixed #24950 -- Added unicode_literals to models.py in app templateMarkus Holtermann
Thanks Tim Graham for the patch
2015-05-20Refs #24652 -- Used SimpleTestCase where appropriate.Simon Charette
2015-05-13Fixed #24742 -- Made runserver.check_migrations ignore read-only databasesClaude Paroz
Thanks Luis Del Giudice for the report, and Aymeric Augustin and Markus Holtermann for the reviews.
2015-04-04Fixed #24571 -- Restored testserver positional arguments parsingClaude Paroz
Thanks Domas Lapinskas for the report and Tim Graham for the review.
2015-02-23Guaranteed removal of temporary files during tests.Aymeric Augustin
Dropped the DJANGO_TEST_TEMP_DIR environment variable. Before this change, proper removal depended on the developer passing dir=os.environ['DJANGO_TEST_TMP_DIR'] to tempfile functions.
2015-02-17Refs #24324 -- Fixed Python 2 test failures when path to Django source ↵Tim Graham
contains non-ASCII characters.
2015-02-11Prevented some test commands from needlessly running system checks.Tim Graham
This is a performance optimization and also fixes test errors with the upcoming merge of contrib tests into tests/. The tests failed on MySQL because the models with GeometryField were being checked but the non-GIS MySQL backend didn't know how to handle them.
2015-02-06Sorted imports with isort; refs #23860.Tim Graham
2015-01-18Removed support for syncing apps without migrations per deprecation timeline.Tim Graham
Kept support for creating models without migrations when running tests (especially for Django's test suite).
2015-01-17Removed unused imports from previous commit.Tim Graham
2015-01-17Removed BaseCommand.requires_model_validation per deprecation timeline.Tim Graham
2015-01-17Removed support for custom SQL per deprecation timeline.Tim Graham
2014-12-30Applied ignore_warnings to Django testsClaude Paroz
2014-12-29Fixed #21255 -- Closed connections after management command ranClaude Paroz
Thanks kabakov.as@gmail.com for the report, and Aymeric Augustin, Simon Charette for the reviews.
2014-12-26Replaced sqlall in some bash_completion/admin_scripts tests.Tim Graham
sqlall will be removed in Django 1.9, so now's a good time to remove its usage where it's not important.
2014-11-03Fixed #23620 -- Used more specific assertions in the Django test suite.Berker Peksag
2014-10-22Refactored color_style() and no_style() to improve testability. Refs #23663.Loic Bistuer
This includes the following improvements: - The type of the style object is now called 'Style' rather than 'dummy'. - The new make_style() function allows generating a Style object directly from a config string. Before the only way to get a style object was through the environ and it also required that the terminal supported colors which isn't necessarily the case when testing. - The output of no_style() is now cached with @lru_cache. - The output of no_style() now has the same set of attributes as the other Style objects. Previously it allowed anything to pass through with __getattr__.
2014-10-22Fixed #23686 -- Tweak color output of the system check framework.Loic Bistuer
Thanks Tim Graham for the review.
2014-10-22Made testing of stdout and stderr more consistent.Loic Bistuer
Refs #23663.
2014-10-22Fixed #23663 -- Initialize output streams for BaseCommand in __init__().Loic Bistuer
This helps with testability of management commands. Thanks to trac username daveoncode for the report and to Tim Graham and Claude Paroz for the reviews.
2014-10-22Fixed #23107 -- Made runserver output respect --no-color.Loic Bistuer
This commit reverts 67d7da5fb9498b811f0168f5df2308ad4743027f. The previous fix changed the environment globally, which meant that any call to `call_command(no_color=True)` prevented further `call_command` with color. This fix still relies on the environment because it's currently the only way to reach WSGIRequestHandler, but it's now limited to the `runserver` command. This seems an acceptable compromise considering `runserver` runs indefinitely. Thanks Tim Graham for the review.
2014-09-17Fixed #23495 -- Stopped swallowing real settings import errorClaude Paroz
Thanks papaloizouc for the report.
2014-08-18Fixed #23136 -- Added a message when sqlclear does nothingGabriel Muñumel
2014-07-30Fixed #23107 -- Made runserver output respect --no-color.areski
2014-06-19Fixed #22835 -- Deprecated NoArgsCommand.Maxime Turcotte