| 
									
										
										
										
											2009-07-19 21:01:52 +00:00
										 |  |  | """Main entry point""" | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | import sys | 
					
						
							|  |  |  | if sys.argv[0].endswith("__main__.py"): | 
					
						
							| 
									
										
										
										
											2012-09-28 15:14:37 +01:00
										 |  |  |     import os.path | 
					
						
							|  |  |  |     # We change sys.argv[0] to make help message more useful | 
					
						
							|  |  |  |     # use executable without path, unquoted | 
					
						
							|  |  |  |     # (it's just a hint anyway) | 
					
						
							|  |  |  |     # (if you have spaces in your executable you get what you deserve!) | 
					
						
							|  |  |  |     executable = os.path.basename(sys.executable) | 
					
						
							|  |  |  |     sys.argv[0] = executable + " -m unittest" | 
					
						
							|  |  |  |     del os | 
					
						
							| 
									
										
										
										
											2009-07-19 21:01:52 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2010-03-22 00:15:53 +00:00
										 |  |  | __unittest = True | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-03-27 16:05:26 +02:00
										 |  |  | from .main import main | 
					
						
							| 
									
										
										
										
											2010-03-22 00:15:53 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2009-07-19 21:01:52 +00:00
										 |  |  | main(module=None) |