'Application names will be autocompleted for an AppCommand'

def test_app_completion(self):

    self._user_input('django-admin.py    sqlall    a')
    output = self._run_autocomplete()
    app_labels = [name.split('.')[(-1)] for name in settings.INSTALLED_APPS]
    self.assertEqual(output, sorted((label for label in app_labels if label.startswith('a'))))
