a
    Lcò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   úg/home/httpd/docs/test/DocsMgr/lib/python3.9/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   