Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed #2490: Added a polite note to runtests.py about setting DJANGO_…

…SETTINGS_MODULE or --settings.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@4628 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 516aa4436c7e51ba6b6d28893a29a1310eafed36 1 parent b581d73
@jacobian jacobian authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 tests/runtests.py
View
4 tests/runtests.py
@@ -148,5 +148,7 @@ def django_tests(verbosity, tests_to_run):
options, args = parser.parse_args()
if options.settings:
os.environ['DJANGO_SETTINGS_MODULE'] = options.settings
-
+ elif "DJANGO_SETTINGS_MODULE" not in os.environ:
+ parser.error("DJANGO_SETTINGS_MODULE is not set in the environment. "
+ "Set it or use --settings.")
django_tests(int(options.verbosity), args)
Please sign in to comment.
Something went wrong with that request. Please try again.