
    tni	                         d Z ddlZddlZddlmZ ddlmZ ddlm	Z	  G d dej
                  Zedk    r ej                     dS dS )	z" Tests for the user_agent module.     N)patch)__version__)construct_user_agentc            	          e Zd ZdZ edd           edd           edd           ed	d
          d                                                 Z edd           edd           edd           ed	d           ej        ej        ddi          d                                                             Z	dS )TestConstructUserAgentz'Test the construct_user_agent function.z!runpod.user_agent.platform.systemWindows)return_valuez"runpod.user_agent.platform.release10z"runpod.user_agent.platform.machineAMD64z)runpod.user_agent.platform.python_versionz3.8.10c                     dt           j        v rt           j        d= dt           d}|                     t	                      |           |j        sJ |j        sJ |j        sJ |j        sJ dS )zDTest the User-Agent string without specifying an integration method.RUNPOD_UA_INTEGRATIONRunPod-Python-SDK/z+ (Windows 10; AMD64) Language/Python 3.8.10N)osenvironrunpod_versionassertEqualr   calledselfmock_python_versionmock_machinemock_releasemock_systemexpected_uas         R/var/www/html/gpu-tools/venv/lib/python3.11/site-packages/tests/test_user_agent.py#test_user_agent_without_integrationz:TestConstructUserAgent.test_user_agent_without_integration   s     #bj00
23f>fff-//==="))))""""""""!!!!!!    Linuxz5.4x86_64z3.9.5r   SkyPilotc                    dt            d}dt          j        d<   |                     t	                      |           t          j                            d           |j        sJ |j        sJ |j        sJ |j        sJ dS )z@Test the User-Agent string with an integration method specified.r   z? (Linux 5.4; x86_64) Language/Python 3.9.5 Integration/SkyPilotr    r   N)r   r   r   r   r   popr   r   s         r    test_user_agent_with_integrationz7TestConstructUserAgent.test_user_agent_with_integration!   s     {>zzz.8
*+-//===

.///"))))""""""""!!!!!!r   N)
__name__
__module____qualname____doc__r   r   dictr   r   r#    r   r   r   r      s<       11
U.YGGG
U/dCCC
U/gFFF
U6XNNN" " ON GF DC HG" U.WEEE
U/eDDD
U/hGGG
U6WMMMUZ
4jABB" " CB NM HG ED FE
" " "r   r   __main__)r'   r   unittestunittest.mockr   runpodr   r   runpod.user_agentr   TestCaser   r$   mainr)   r   r   <module>r1      s    ( ( 				        0 0 0 0 0 0 2 2 2 2 2 2(" (" (" (" ("X. (" (" ("V zHMOOOOO r   