mirror of
				https://github.com/django/django.git
				synced 2025-11-03 21:25:09 +00:00 
			
		
		
		
	This adds a case that was missed in r9924: underscore handling. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10078 bcc190cf-cafb-0310-a4f2-bffc1f526a37
		
			
				
	
	
		
			27 lines
		
	
	
	
		
			555 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
	
		
			555 B
		
	
	
	
		
			Python
		
	
	
	
	
	
import os
 | 
						|
import sys
 | 
						|
import time
 | 
						|
 | 
						|
from django.conf import Settings
 | 
						|
 | 
						|
__test__ = {"API_TESTS": """
 | 
						|
Test the globbing of INSTALLED_APPS.
 | 
						|
 | 
						|
>>> old_sys_path = sys.path
 | 
						|
>>> sys.path.append(os.path.dirname(os.path.abspath(__file__)))
 | 
						|
 | 
						|
>>> old_tz = os.environ["TZ"]
 | 
						|
>>> settings = Settings('test_settings')
 | 
						|
 | 
						|
>>> settings.INSTALLED_APPS
 | 
						|
['parent.app', 'parent.app1', 'parent.app_2']
 | 
						|
 | 
						|
>>> sys.path = old_sys_path
 | 
						|
 | 
						|
# Undo a side-effect of installing a new settings object.
 | 
						|
>>> if hasattr(time, "tzset"):
 | 
						|
...     os.environ["TZ"] = old_tz
 | 
						|
...     time.tzset()
 | 
						|
 | 
						|
"""}
 | 
						|
 |