MCPcopy Create free account
hub / github.com/ipython/ipython / test_nocase_showall

Method test_nocase_showall

IPython/utils/tests/test_wildcard.py:98–113  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

96 self.assertEqual(a,res)
97
98 def test_nocase_showall(self):
99 ns=root.__dict__
100 tests=[
101 ("a*", ["abbot","abel","ABEL","active","arna",]),
102 ("?b*.?o*",["abbot.koppel","abbot.loop","abel.koppel","abel.loop",
103 "ABEL.koppel","ABEL.loop",]),
104 ("_a*", ["_apan","_APAN"]),
105 ("_*anka", ["__anka","__ANKA",]),
106 ("_*a*", ["__anka","__ANKA","_apan","_APAN"]),
107 ]
108 for pat,res in tests:
109 res.sort()
110 a=sorted(wildcard.list_namespace(ns,"all",pat,ignore_case=True,
111 show_all=True).keys())
112 a.sort()
113 self.assertEqual(a,res)
114
115 def test_dict_attributes(self):
116 """Dictionaries should be indexed by attributes, not by keys. This was

Callers

nothing calls this directly

Calls 1

sortMethod · 0.80

Tested by

no test coverage detected