
    vKgq                     P    S r SSKrSSKrSSKJr  SSKJr  SSKJr   " S S5      r	g)	zinstall_scripts tests    N)install_scripts)Distribution   )contextsc                      \ rS rSr\" SSS/0SS9rSrSrS	rSS jr	\
R                  R                  \R                  S:H  SS9S 5       r\
R                  R                  \R                  S:g  SS9S 5       r\
R                  R                  \R                  S:H  SS9S 5       r\
R                  R                  \R                  S:g  SS9S 5       rSrg
)TestInstallScripts   fooconsole_scriptszfoo=foo:fooz0.0)nameentry_pointsversionz%/usr/dummy-test-path/local/bin/pythonz/usr/bin/env dummy-test-pythonz6C:\Dummy Test Path\Program Files\Python 3.6\python.exeNc                 0   [        U R                  5      nSUl        [        U5      nXl        Ub  UR                  S5      nX%l        UR                  5         [        R                  " 5          UR                  5         S S S 5        g ! , (       d  f       g = f)Nzsetup.pybuild_scripts)r   settingsscript_namer   install_dirget_finalized_command
executableensure_finalizedr   quietrun)selfr   r   distcmdbss         e/var/www/highfloat_scraper/venv/lib/python3.13/site-packages/setuptools/tests/test_install_scripts.py_run_install_scripts'TestInstallScripts._run_install_scripts   sm    DMM*%d#%!**?;B&M^^GGI s   -B
Bwin32znon-Windows only)reasonc                    SU R                   -  nUR                  SU R                   5        UR                  5          U R                  [	        U5      5        [        [	        UR                  S5      5      SSS9 nUR                  5       nSSS5        SSS5        WU:X  d   eg! , (       d  f       N= f! , (       d  f       N(= f)z\
Ensure that shebang is not quoted on Unix when getting the Python exe
from sys.executable.
#!%s
sys.executabler
   rutf-8encodingN)unix_exesetattras_cwdr   stropenjoinreadliner   tmpdirmonkeypatchexpectedfactuals         r   !test_sys_executable_escaping_unix4TestInstallScripts.test_sys_executable_escaping_unix#   s     dmm+,dmm<]]_%%c&k2c&++e,-sWE F  !!! FE _#   >B5:B$B5$
B2	.B55
CzWindows onlyc                    SU R                   -  nUR                  SU R                   5        UR                  5          U R                  [	        U5      5        [        [	        UR                  S5      5      SSS9 nUR                  5       nSSS5        SSS5        WU:X  d   eg! , (       d  f       N= f! , (       d  f       N(= f)zs
Ensure that shebang is quoted on Windows when getting the Python exe
from sys.executable and it contains a space.
#!"%s"
r$   foo-script.pyr%   r&   r'   N)	win32_exer*   r+   r   r,   r-   r.   r/   r0   s         r   "test_sys_executable_escaping_win325TestInstallScripts.test_sys_executable_escaping_win321   s     .,dnn=]]_%%c&k2c&++o67wOST P  !!! PO _r8   c                 j   SU R                   -  nUR                  5          U R                  [        U5      U R                   5        [	        [        UR                  S5      5      SSS9 nUR                  5       nSSS5        SSS5        WU:X  d   eg! , (       d  f       N= f! , (       d  f       N(= f)zk
Ensure that shebang on Unix is not quoted, even when
a value with spaces
is specified using --executable.
r#   r
   r%   r&   r'   N)unix_spaces_exer+   r   r,   r-   r.   r/   r   r1   r3   r4   r5   s        r   )test_executable_with_spaces_escaping_unix<TestInstallScripts.test_executable_with_spaces_escaping_unix?   s     d222]]_%%c&k43G3GHc&++e,-sWE F  !!! FE _s$   A	B$)B:B$
B!	B$$
B2c                 v   SU R                   -  nUR                  5          U R                  [        U5      SU R                   -   S-   5        [	        [        UR                  S5      5      SSS9 nUR                  5       nSSS5        SSS5        WU:X  d   eg! , (       d  f       N= f! , (       d  f       N(= f)z}
Ensure that shebang on Windows is quoted when
getting a path with spaces
from --executable, that is itself properly quoted.
r:   "r;   r%   r&   r'   N)r<   r+   r   r,   r-   r.   r/   rA   s        r   "test_executable_arg_escaping_win325TestInstallScripts.test_executable_arg_escaping_win32M   s     .]]_%%c&k33G#3MNc&++o67wOST P  !!! PO _s$   AB*/B B*
B'	#B**
B8 )N)__name__
__module____qualname____firstlineno__dictr   r)   r@   r<   r   pytestmarkskipifsysplatformr6   r=   rB   rF   __static_attributes__rH       r   r   r      s    '-9H
 7H6OLI
 [[/8JK" L" [[/G" H" [[/8JK" L" [[/G" H"rT   r   )
__doc__rQ   rN   "setuptools.command.install_scriptsr   setuptools.distr    r   r   rH   rT   r   <module>rY      s#     
  > ( L" L"rT   