mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Removed unnecessary capturing/hiding of stdout/stderr in various tests.
This commit is contained in:
committed by
Mariusz Felisiak
parent
a8d175c297
commit
687cb38a05
@@ -1366,8 +1366,7 @@ class ManageTestserver(SimpleTestCase):
|
||||
@mock.patch.object(LoaddataCommand, 'handle', return_value='')
|
||||
@mock.patch.object(RunserverCommand, 'handle', return_value='')
|
||||
def test_params_to_runserver(self, mock_runserver_handle, mock_loaddata_handle, mock_create_test_db):
|
||||
out = StringIO()
|
||||
call_command('testserver', 'blah.json', stdout=out)
|
||||
call_command('testserver', 'blah.json')
|
||||
mock_runserver_handle.assert_called_with(
|
||||
addrport='',
|
||||
force_color=False,
|
||||
@@ -1678,7 +1677,7 @@ class CommandTypes(AdminScriptTestCase):
|
||||
A command called from the command line should close connections after
|
||||
being executed (#21255).
|
||||
"""
|
||||
command = BaseCommand(stderr=StringIO())
|
||||
command = BaseCommand()
|
||||
command.check = lambda: []
|
||||
command.handle = lambda *args, **kwargs: args
|
||||
with mock.patch('django.core.management.base.connections') as mock_connections:
|
||||
|
||||
Reference in New Issue
Block a user