Ë
    ¤ehQ  ã                   óP   — d dl Zd dlZd dlmZmZ d dlmZ d dl	m
Z
  G d„ d«      Zy)é    N)ÚIndexÚ
date_range©Úcartesian_productc                   óú   — e Zd Zd„ Zd„ Zd„ Zd„ Zej                  j                  dg g gddgg gg g d¢gg«      d	„ «       Z
d
„ Zej                  j                  dddgddgdgdgddgddgdgdgg«      d„ «       Zd„ Zy)ÚTestCartesianProductc                 óö   — t        d«      ddg}}t        ||g«      \  }}t        j                  g d¢«      }t        j                  g d¢«      }t	        j
                  ||«       t	        j
                  ||«       y )NÚABCé   é   )ÚAr   ÚBr   ÚCr   )r   r   r   r   r   r   )Úlistr   ÚnpÚarrayÚtmÚassert_numpy_array_equal)ÚselfÚxÚyÚresult1Úresult2Ú	expected1Ú	expected2s          ú\/var/www/skyplay_api_hub/venv/lib/python3.12/site-packages/pandas/tests/reshape/test_util.pyÚtest_simplez TestCartesianProduct.test_simple   sd   € Ü�E‹{˜Q ˜Gˆ1ˆÜ,¨a°¨VÓ4Ñˆ�Ü—H‘HÒ;Ó<ˆ	Ü—H‘HÒ2Ó3ˆ	Ü
×#Ñ# G¨YÔ7Ü
×#Ñ# G¨YÕ7ó    c                 ó  — t        dd¬«      }d„ t        ||g«      D «       \  }}t        g d¢t        j                  ¬«      }t        g d¢t        j                  ¬«      }t        j                  ||«       t        j                  ||«       y )Nú
2000-01-01é   )Úperiodsc              3   óF   K  — | ]  }t        |«      j                  –— Œ y ­w©N)r   Úday)Ú.0r   s     r   ú	<genexpr>z:TestCartesianProduct.test_datetimeindex.<locals>.<genexpr>   s   è ø€ ÒL¨QœE !›HŸL�LÑLùs   ‚!)r   r   r!   r!   ©Údtype)r   r!   r   r!   )r   r   r   r   Úint32r   Úassert_index_equal)r   r   r   r   r   r   s         r   Útest_datetimeindexz'TestCartesianProduct.test_datetimeindex   si   € ô �|¨QÔ/ˆÙLÔ2CÀQÈÀFÓ2KÔLÑˆ�Üš,¬b¯h©hÔ7ˆ	Üš,¬b¯h©hÔ7ˆ	Ü
×Ñ˜g yÔ1Ü
×Ñ˜g yÕ1r   c                 ó¼   — t        ddd¬«      }t        j                  ddg«      }t        ||g«      \  }}|j	                  d«      }t        j                  ||«       y )Nr    r!   ú
US/Pacific©r"   Útzé   é   )r   r   r   r   Úrepeatr   r+   ©r   r   r   r   r   Úexpecteds         r   Útest_tzaware_retainedz*TestCartesianProduct.test_tzaware_retained   sR   € Ü�|¨Q°<Ô@ˆÜ�H‰H�a˜�VÓˆÜ,¨a°¨VÓ4Ñˆ�à—8‘8˜A“;ˆÜ
×Ñ˜g xÕ0r   c                 óÚ   — t        ddd¬«      j                  d«      }t        j                  ddg«      }t	        ||g«      \  }}|j                  d«      }t        j                  ||«       y )Nr    r!   r.   r/   Úcategoryr1   r2   )r   Úastyper   r   r   r3   r   r+   r4   s         r   Ú!test_tzaware_retained_categoricalz6TestCartesianProduct.test_tzaware_retained_categorical'   s]   € Ü�|¨Q°<Ô@×GÑGÈ
ÓSˆÜ�H‰H�a˜�VÓˆÜ,¨a°¨VÓ4Ñˆ�à—8‘8˜A“;ˆÜ
×Ñ˜g xÕ0r   zx, yr   r   )ÚaÚbÚcc                 óL  — t        j                  g t        j                  |«      j                  ¬«      }t        j                  g t        j                  |«      j                  ¬«      }t	        ||g«      \  }}t        j                  ||«       t        j                  ||«       y )Nr(   )r   r   Úasarrayr)   r   r   r   )r   r   r   r   r   r   r   s          r   Ú
test_emptyzTestCartesianProduct.test_empty/   ss   € ô —H‘H˜R¤r§z¡z°!£}×':Ñ':Ô;ˆ	Ü—H‘H˜R¤r§z¡z°!£}×':Ñ':Ô;ˆ	Ü,¨a°¨VÓ4Ñˆ�Ü
×#Ñ# G¨YÔ7Ü
×#Ñ# G¨YÕ7r   c                 ó,   — t        g «      }g }||k(  sJ ‚y r$   r   )r   Úresultr5   s      r   Útest_empty_inputz%TestCartesianProduct.test_empty_input8   s   € ä" 2Ó&ˆØˆØ˜Ò!Ð!Ñ!r   ÚXr!   r;   r<   c                 ó€   — d}t        j                  t        |¬«      5  t        |¬«       d d d «       y # 1 sw Y   y xY w)Nz'Input must be a list-like of list-likes©Úmatch©rD   )ÚpytestÚraisesÚ	TypeErrorr   )r   rD   Úmsgs      r   Útest_invalid_inputz'TestCartesianProduct.test_invalid_input>   s4   € ð 8ˆä�]‰]œ9¨CÔ0ñ 	#Ü Õ"÷	#÷ 	#ñ 	#ús   ž4´=c           	      óR  — d}t        j                  t        |¬«      5  t        d«      D �cg c](  }t	        j
                  ddt        j                  ¬«      ‘Œ* c}t	        j
                  dt        j                  ¬«      gz   }t        |¬«       d d d «       y c c}w # 1 sw Y   y xY w)	Nz+Product space too large to allocate arrays!rF   é   r   r   r(   i;  rH   )rI   rJ   Ú
ValueErrorÚranger   ÚarangeÚint16r   )r   rL   ÚiÚdimss       r   Útest_exceed_product_spacez.TestCartesianProduct.test_exceed_product_spaceG   s~   € à;ˆä�]‰]œ:¨SÔ1ñ 	&Ü>CÀB»iÖH¸”B—I‘I˜a ¬2¯8©8Ö4ÒHÜ—‘˜5¬¯©Ô1ðLñ ˆDô  Õ%÷		&ð 	&ùÚH÷	&ð 	&ús   žB¬-BÁ6BÂBÂB&N)Ú__name__Ú
__module__Ú__qualname__r   r,   r6   r:   rI   ÚmarkÚparametrizer@   rC   rM   rV   © r   r   r   r      s¯   „ ò8ò2ò1ò1ð ‡[�[×Ñ˜V r¨2 h°!°Q°¸°¸rÂ?Ð>SÐ%TÓUñ8ó Vð8ò"ð ‡[�[×ÑØˆa�!��q˜!�f ˜s A˜h¨¨c¨U°S¸#°JÀ#ÀÈÀÐMóñ#óð#ó&r   r   )Únumpyr   rI   Úpandasr   r   Úpandas._testingÚ_testingr   Úpandas.core.reshape.utilr   r   r\   r   r   ú<module>rb      s$   ðÛ Û ÷õ Ý 6÷C&ò C&r   