Ticket #20349 Don't load test suite when not needed #1041

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
3 participants
@collinanderson
Contributor

collinanderson commented May 3, 2013

I noticed that django/contrib/auth/hashers.py is loading the settings_changed signal from the test suite. This ends up also loading the whole test suite in addition.

All of the other code that handles the settings_changed signal is kept inside the test suite itself. I assume this code is kept out of the test suite because of the "core shouldn't be aware of contrib" rule. Seems to me it's more important to avoid unnecessarily loading the test suite on a production website.

Yes, I realize this is picky, but we're perfectionists, right?

https://code.djangoproject.com/ticket/20349

@ramiro

This comment has been minimized.

Show comment Hide comment
@ramiro

ramiro May 16, 2013

Member

I don't see how the code could actually load the test suite. Maybe you meant the django.test package?

Member

ramiro commented May 16, 2013

I don't see how the code could actually load the test suite. Maybe you meant the django.test package?

@collinanderson

This comment has been minimized.

Show comment Hide comment
@collinanderson

collinanderson May 16, 2013

Contributor

ohh. yes. the "test" package. not quite as bad, though it's still a large amount of code that is unnecessarily loaded.

Contributor

collinanderson commented May 16, 2013

ohh. yes. the "test" package. not quite as bad, though it's still a large amount of code that is unnecessarily loaded.

@aaugustin

This comment has been minimized.

Show comment Hide comment
@aaugustin

aaugustin May 19, 2013

Owner

As explained by Carl in the ticket this PR can't work.

Owner

aaugustin commented May 19, 2013

As explained by Carl in the ticket this PR can't work.

@aaugustin aaugustin closed this May 19, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment