a
    [f                     @   s8   d dl mZ d dlmZ d dlmZ G dd deZdS )    )call_command)BaseCommand)
connectionc                   @   s$   e Zd ZdZg Zdd Zdd ZdS )Commandz>Runs a development server with data from the given fixture(s).c                 C   sN   |j ddddd |j dddd	d
d |j dddd |j dddddd d S )NargsZfixture*z6Path(s) to fixtures to load before running the server.)metavarnargshelpz	--noinputz
--no-inputstore_falseinteractivez:Tells Django to NOT prompt the user for input of any kind.)actiondestr
   z
--addrport z0Port number or ipaddr:port to run the server on.)defaultr
   z--ipv6z-6
store_trueuse_ipv6z$Tells Django to use an IPv6 address.)add_argument)selfparser r   |C:\Users\91910\OneDrive\Desktop\vts_admin_rebuild-master\vts\Lib\site-packages\django/core/management/commands/testserver.pyadd_arguments   s2    zCommand.add_argumentsc                 O   sn   |d }|d }t jj|| dd}tdg|R i d|i d| }t jj}td|d |d|d	 |d
 d S )N	verbosityr   F)r   Zautoclobber	serializeZloaddatazg
Server stopped.
Note that the test database, %r, has not been deleted. You can explore it on your own.Z	runserveraddrportr   )r   shutdown_messageZuse_reloaderr   use_threading)r   ZcreationZcreate_test_dbr   featuresZ#test_db_allows_multiple_connections)r   Zfixture_labelsoptionsr   r   Zdb_namer   r   r   r   r   handle&   s&    zCommand.handleN)__name__
__module____qualname__r
   Zrequires_system_checksr   r    r   r   r   r   r      s   r   N)Zdjango.core.managementr   Zdjango.core.management.baser   Z	django.dbr   r   r   r   r   r   <module>   s   