U
    _{f@                     @  sv   d dl mZ d dlZd dlZd dlmZ d dlmZ G dd dZ	G dd de	Z
G dd	 d	e	ZG d
d de	ZdS )    )annotationsN)apic                   @  s   e Zd ZdddZdS )BaseNc                 C  sJ   t dd t|D }|d k	r2t t|t| }t |}t|| d S )Nc                 s  s$   | ]}| d s|dkr|V  qdS )__r   N)
startswith).0f r	   X/var/www/html/Darija-Ai-API/env/lib/python3.8/site-packages/pandas/tests/api/test_api.py	<genexpr>   s    
  zBase.check.<locals>.<genexpr>)sorteddirsettmZassert_almost_equal)self	namespaceexpectedignoredresultr	   r	   r
   check   s    z
Base.check)N)__name__
__module____qualname__r   r	   r	   r	   r
   r   
   s   r   c                (   @  s  e Zd ZU dddgZdddddd	d
ddg	ZddddgZdddgZddddddddddddd d!d"d#d$d%d&d'd(d)d*d+d,d-d.d/d0d1d2d3d4d5d6d7d8d9d:d;g(Zg Zd<e	d=< g Z
d<e	d>< d?d@dAdBdCdDdEdFdGdHdIdJdKdLdMdNdOdPdQdRdSdTdUdVdWdXdYdZd[d\d]gZd^d_d`dadbdcgZdddedfdgdhdidjdkdldmdndodpdqdrdsdtdudvdwgZdxgZdydzd{d|gZg Zd<e	d}< g Zd<e	d~< ddddddgZdd Zdd Zdd ZdS )	TestPDApitestslocaleZconftestr   ZarraysoptionstesttestingerrorsZplottingioZtseriescompatcorepandasutilZ
IndexSliceZNaTZNAZ
ArrowDtypeZCategoricalZCategoricalIndexZ	DataFrameZ
DateOffsetZDatetimeIndexZ	ExcelFileZExcelWriterFlagsZGrouperZHDFStoreIndexZ
MultiIndexZPeriodZPeriodIndexZ
RangeIndexZSeriesZSparseDtypeZStringDtypeZ	TimedeltaZTimedeltaIndex	TimestampZIntervalZIntervalIndexZCategoricalDtypeZPeriodDtypeZIntervalDtypeZDatetimeTZDtypeZBooleanDtypeZ	Int8DtypeZ
Int16DtypeZ
Int32DtypeZ
Int64DtypeZ
UInt8DtypeZUInt16DtypeZUInt32DtypeZUInt64DtypeZFloat32DtypeZFloat64DtypeZNamedAggz	list[str]deprecated_classesmodulesarrayZbdate_rangeconcatZcrosstabcutZ
date_rangeZinterval_rangeevalZ	factorizeZget_dummiesZfrom_dummiesZ
infer_freqZisnaZisnullZlreshapeZmeltZnotnaZnotnulloffsetsmergeZmerge_orderedZ
merge_asofZperiod_rangeZpivotZpivot_tableZqcutZshow_versionsZtimedelta_rangeuniqueZvalue_countsZwide_to_longZreset_optionZdescribe_option
get_optionZoption_contextZ
set_optionZset_eng_float_formatZread_clipboardZread_csvZ
read_excelZread_fwfZread_gbqZread_hdfZ	read_htmlZread_xml	read_jsonZread_pickleZread_sasZread_sqlZread_sql_queryZread_sql_tableZ
read_stataZ
read_tableZread_featherZread_parquetZread_orcZ	read_spssZjson_normalizeto_datetimeZ
to_numericZ	to_pickleZto_timedeltadeprecated_funcs_in_futuredeprecated_funcs_configZ_libsZ_is_numpy_dev_testingZ_typing_versionc                 C  sX   | j | j | j | j | j | j | j | j | j | j	 | j
 }| jt|| jd d S )N)r   r   r   )
public_libprivate_libmiscr)   classesfuncsfuncs_option
funcs_read
funcs_jsonfuncs_toprivate_modulesr   pdr   )r   Z
checktheser	   r	   r
   test_api   s.    	
zTestPDApi.test_apic                 C  sr   t | j| j | j | j | j | j | j | j | j	 t | j
 }t tj}|| }|r^t|| }|rntd S N)r   r9   r;   r)   r<   r=   r>   r?   r@   rA   r(   rC   __all__AssertionError)r   r   actualZ
extraneousmissingr	   r	   r
   test_api_all   s4    

zTestPDApi.test_api_allc              
   C  s@   | j | j | j }|D ]$}tt tt|}W 5 Q R X qd S rE   )r(   r5   r4   r   Zassert_produces_warningFutureWarninggetattrrC   )r   Zdeprecated_listZdepr_r	   r	   r
   	test_depr   s    zTestPDApi.test_deprN)r   r   r   r   r9   r:   r;   r<   r(   __annotations__r)   r=   r>   r?   r@   rA   r4   r5   rB   rD   rJ   rN   r	   r	   r	   r
   r      s  


,$	r   c                   @  s    e Zd ZddddgZdd ZdS )TestApitypes
extensionsZindexersZinterchangec                 C  s   |  t| j d S rE   )r   r   allowedr   r	   r	   r
   rD      s    zTestApi.test_apiN)r   r   r   rS   rD   r	   r	   r	   r
   rP      s   rP   c                   @  s(   e Zd ZddddgZdd Zdd Zd	S )
TestTestingZassert_frame_equalZassert_series_equalZassert_index_equalZassert_extension_array_equalc                 C  s   ddl m} | || j d S )Nr   )r   )r#   r   r   r=   )r   r   r	   r	   r
   test_testing   s    zTestTesting.test_testingc              	   C  s&   t jtdd tjj W 5 Q R X d S )Nfoo)match)pytestZraisesAttributeErrorrC   r$   rW   rT   r	   r	   r
   test_util_in_top_level   s    z"TestTesting.test_util_in_top_levelN)r   r   r   r=   rV   r[   r	   r	   r	   r
   rU      s   rU   )
__future__r   rY   r#   rC   r   Zpandas._testingr7   r   r   r   rP   rU   r	   r	   r	   r
   <module>   s    S