
    -Ph                         d Z ddlZddlZddlmZ ddlZddlmZmZ ddlm	Z
 ddlmZmZ ej        j        d	             ZdS )
z;
Test the entire process of creating a Pooch and using it.
    N)Path   )createos_cache)__version__   )check_tiny_datacapture_logc                     t          d          } |                                 r!t          j        t	          |                      t          | dt          dd          }|j                                        rJ |                    t          t          j                            t                    dd                     dD ]<}t                      5 }|                    |          }|                                                                d	         d
k    sJ 	 ddd           n# 1 swxY w Y   t%          |           t'          |dd          5 }|                    d           ddd           n# 1 swxY w Y   t                      5 }|                    |          }|                                                                d	         dk    sJ 	 ddd           n# 1 swxY w Y   t%          |           >dS )z(Fetch a data file from the local storagezpooch-testingz5https://github.com/fatiando/pooch/raw/{version}/data/mainPOOCH_DATA_DIR)pathbase_urlversionversion_devenvdatazregistry.txt)ztiny-data.txtzsubdir/tiny-data.txtr   DownloadingNwzutf-8)encodingzThe data is now differentUpdating)r   existsshutilrmtreestrr   full_versionabspathload_registryr   osr   dirname__file__r
   fetchgetvaluesplitr	   openwrite)r   puptargetlog_filefnamefins         \/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/pooch/tests/test_integration.pytest_create_and_fetchr-      s    O$$D{{}} !c$ii   
H  C {!!#####d27??844fnMMNNN;  ]] 	ChIIf%%E$$&&,,..q1]BBBBB	C 	C 	C 	C 	C 	C 	C 	C 	C 	C 	C 	C 	C 	C 	C 	%w/// 	33II1222	3 	3 	3 	3 	3 	3 	3 	3 	3 	3 	3 	3 	3 	3 	3]] 	@hIIf%%E$$&&,,..q1Z?????	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	@ 	 s8   AD''D+	.D+	E55E9	<E9	AG##G'	*G'	)__doc__r   r   pathlibr   pytest r   r   r   r   utilsr	   r
   marknetworkr-        r,   <module>r7      s     
			                 * * * * * * / / / / / / / /     r6   