mirror of
https://github.com/django/django.git
synced 2025-08-03 18:38:50 +00:00
Prevented some test commands from needlessly running system checks.
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.
This commit is contained in:
parent
19188826b4
commit
197dd4b8f1
3 changed files with 12 additions and 1 deletions
|
@ -1577,6 +1577,7 @@ class CommandTypes(AdminScriptTestCase):
|
|||
being executed (#21255).
|
||||
"""
|
||||
command = BaseCommand(stderr=StringIO())
|
||||
command.check = lambda: []
|
||||
command.handle = lambda *args, **kwargs: args
|
||||
with mock.patch('django.core.management.base.connections') as mock_connections:
|
||||
command.run_from_argv(['', ''])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue