1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
U
­ý°d×ã@s>ddlZddlZddlmZmZddlmZGdd„dƒZ    dS)éN)ÚIndexÚ
MultiIndexc@sveZdZej dde d¡g¡dd„ƒZej dddgddgg¡dd    „ƒZ    d
d „Z
ej d d gd d gg¡dd„ƒZ dS)ÚTestIndexConstructorÚvalueéc    Cs2d|›d}tjt|dt|ƒW5QRXdS)Nz?Index\(\.\.\.\) must be called with a collection of some kind, z  was passed©Úmatch)ÚpytestÚraisesÚ    TypeErrorr)ÚselfrÚmsg©rúhd:\z\workplace\vscode\pyvenv\venv\Lib\site-packages\pandas/tests/indexes/base_class/test_constructors.pyÚtest_constructor_corners
ÿz,TestIndexConstructor.test_constructor_cornerÚ
index_vals)ÚArÚBcCs(t|ƒ}t|tƒst‚t|tƒr$t‚dS©N)rÚ
isinstanceÚAssertionErrorr)r rÚindexrrrÚ#test_construction_list_mixed_tuplessz8TestIndexConstructor.test_construction_list_mixed_tuplesc    Cs4d}tjt|dtdddgtdW5QRXdS)Nz!could not convert string to floatrÚaÚbÚc)Zdtype)r    r
Ú
ValueErrorrÚfloat)r r rrrÚtest_constructor_cast!sz*TestIndexConstructor.test_constructor_castÚ
tuple_listrcCs"t|ƒ}t |¡}t ||¡dSr)rrÚ from_tuplesÚtmZassert_index_equal)r rÚresultÚexpectedrrrÚtest_construct_empty_tuples&s
z0TestIndexConstructor.test_construct_empty_tuplesN) Ú__name__Ú
__module__Ú __qualname__r    ÚmarkZ parametrizeÚnpÚint64rrrr$rrrrr s
    
r)
Únumpyr)r    ZpandasrrZpandas._testingZ_testingr!rrrrrÚ<module>s