MCPcopy Create free account
hub / github.com/numpy/numpy / test_smallmask

Method test_smallmask

numpy/ma/tests/test_core.py:2020–2030  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2018 assert_equal(b, array([0, 2, 3], mask=[0, 0, 0]))
2019
2020 def test_smallmask(self):
2021 # Checks the behaviour of _smallmask
2022 a = arange(10)
2023 a[1] = masked
2024 a[1] = 1
2025 assert_equal(a._mask, nomask)
2026 a = arange(10)
2027 a._smallmask = False
2028 a[1] = masked
2029 a[1] = 1
2030 assert_equal(a._mask, zeros(10))
2031
2032 def test_shrink_mask(self):
2033 # Tests .shrink_mask()

Callers

nothing calls this directly

Calls 3

assert_equalFunction · 0.90
arangeFunction · 0.85
zerosFunction · 0.50

Tested by

no test coverage detected