/usr/local/lib64/python3.6/site-packages/pandas/tests/indexes/multi
NameSizeModeActions
__pycache__/-0755rm
conftest.py22160644editdlrm
test_analytics.py69840644editdlrm
test_astype.py9240644editdlrm
test_compat.py35340644editdlrm
test_constructors.py256460644editdlrm
test_conversion.py41890644editdlrm
test_copy.py23410644editdlrm
test_drop.py44280644editdlrm
test_duplicates.py101630644editdlrm
test_equivalence.py70830644editdlrm
test_formats.py77840644editdlrm
test_get_level_values.py35790644editdlrm
test_get_set.py117200644editdlrm
test_indexing.py299070644editdlrm
test_integrity.py84890644editdlrm
test_isin.py31740644editdlrm
test_join.py37880644editdlrm
test_lexsort.py13510644editdlrm
test_missing.py33780644editdlrm
test_monotonic.py69360644editdlrm
test_names.py45930644editdlrm
test_partial_indexing.py33760644editdlrm
test_reindex.py37450644editdlrm
test_reshape.py50410644editdlrm
test_setops.py121810644editdlrm
test_sorting.py84060644editdlrm
test_take.py25010644editdlrm
__init__.py00644editdlrm
Edit: /usr/local/lib64/python3.6/site-packages/pandas/tests/indexes/multi/test_lexsort.py (1351B)
from pandas import MultiIndex class TestIsLexsorted: def test_is_lexsorted(self): levels = [[0, 1], [0, 1, 2]] index = MultiIndex( levels=levels, codes=[[0, 0, 0, 1, 1, 1], [0, 1, 2, 0, 1, 2]] ) assert index.is_lexsorted() index = MultiIndex( levels=levels, codes=[[0, 0, 0, 1, 1, 1], [0, 1, 2, 0, 2, 1]] ) assert not index.is_lexsorted() index = MultiIndex( levels=levels, codes=[[0, 0, 1, 0, 1, 1], [0, 1, 0, 2, 2, 1]] ) assert not index.is_lexsorted() assert index.lexsort_depth == 0 class TestLexsortDepth: def test_lexsort_depth(self): # Test that lexsort_depth return the correct sortorder # when it was given to the MultiIndex const. # GH#28518 levels = [[0, 1], [0, 1, 2]] index = MultiIndex( levels=levels, codes=[[0, 0, 0, 1, 1, 1], [0, 1, 2, 0, 1, 2]], sortorder=2 ) assert index.lexsort_depth == 2 index = MultiIndex( levels=levels, codes=[[0, 0, 0, 1, 1, 1], [0, 1, 2, 0, 2, 1]], sortorder=1 ) assert index.lexsort_depth == 1 index = MultiIndex( levels=levels, codes=[[0, 0, 1, 0, 1, 1], [0, 1, 0, 2, 2, 1]], sortorder=0 ) assert index.lexsort_depth == 0