
    bMh                     @    d dl Z d dlmZ d dlmZ  G d d          ZdS )    N)	DataFramec                       e Zd Zd ZdS )TestSwaplevelc                 t   |}|d                                          }|d                              d          }|d                              dd          }|d                              dd          }|j                            |j                  rJ t          j        ||           t          j        ||           t          j        ||           |                                 }|                     d          }|                     dd          }	|                     dd          }
|j                            |j                  sJ t          j        ||           t          j        ||	           t          j        ||
           |j        }|                     ddd          }|                     dd          j        }t          j        ||           d}t          j        t          |          5  t          t          d	                                                      d d d            d S # 1 swxY w Y   d S )
NAr      firstsecond)axisz,Can only swap levels on a hierarchical axis.)match   )	swaplevelindexequalstmassert_series_equalTassert_frame_equalpytestraises	TypeErrorr   range)self multiindex_dataframe_random_dataframeswappedswapped2swapped3swapped4backback2back3back4ftexpmsgs                 i/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/pandas/tests/frame/methods/test_swaplevel.pytest_swaplevelzTestSwaplevel.test_swaplevel   sF   0*&&((:''**:''1--:''::=''44444
w111
w111
w111  ""!!!$$!!!Q''!!(G44z  -----
tU+++
tU+++
tU+++W,,wq,99oogx002
gs+++<]9C000 	, 	,eAhh))+++	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	,s   1/H--H14H1N)__name__
__module____qualname__r(        r'   r   r      s#        , , , , ,r-   r   )r   pandasr   pandas._testing_testingr   r   r,   r-   r'   <module>r1      sd                , , , , , , , , , ,r-   