MCPcopy Create free account
hub / github.com/dask/dask / test__validate_normalize_axes_02

Function test__validate_normalize_axes_02

dask/array/tests/test_gufunc.py:82–102  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

80
81
82def test__validate_normalize_axes_02():
83 i, o = _validate_normalize_axes(None, 0, False, [("i",), ("i",)], ())
84 assert i == [(0,), (0,)]
85 assert o == [()]
86
87 i, o = _validate_normalize_axes(None, 0, False, [("i",)], ("i",))
88 assert i == [(0,)]
89 assert o == [(0,)]
90
91 i, o = _validate_normalize_axes(None, 0, True, [("i",), ("i",)], ())
92 assert i == [(0,), (0,)]
93 assert o == [(0,)]
94
95 with pytest.raises(ValueError):
96 _validate_normalize_axes(None, (0,), False, [("i",), ("i",)], ())
97
98 with pytest.raises(ValueError):
99 _validate_normalize_axes(None, 0, False, [("i",), ("j",)], ())
100
101 with pytest.raises(ValueError):
102 _validate_normalize_axes(None, 0, False, [("i",), ("j",)], ("j",))
103
104
105def test__validate_normalize_axes_03():

Callers

nothing calls this directly

Calls 1

_validate_normalize_axesFunction · 0.90

Tested by

no test coverage detected