MCPcopy Index your code
hub / github.com/numpy/numpy / test_index

Method test_index

numpy/_core/tests/test_defchararray.py:291–299  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

289 assert_array_equal(C.find(encode('M')), [12, -1])
290
291 def test_index(self):
292 A = self.A()
293
294 def fail():
295 A.index('a')
296
297 assert_raises(ValueError, fail)
298 assert_(np.char.index('abcba', 'b') == 1)
299 assert_(issubclass(np.char.index('abcba', 'b').dtype.type, np.integer))
300
301 def test_isalnum(self):
302 A = self.A()

Callers

nothing calls this directly

Calls 4

AMethod · 0.95
assert_raisesFunction · 0.90
assert_Function · 0.90
indexMethod · 0.45

Tested by

no test coverage detected