(self)
| 4398 | assert_(result is output) |
| 4399 | |
| 4400 | def test_round_with_scalar(self): |
| 4401 | # Testing round with scalar/zero dimension input |
| 4402 | # GH issue 2244 |
| 4403 | a = array(1.1, mask=[False]) |
| 4404 | assert_equal(a.round(), 1) |
| 4405 | |
| 4406 | a = array(1.1, mask=[True]) |
| 4407 | assert_(a.round() is masked) |
| 4408 | |
| 4409 | a = array(1.1, mask=[False]) |
| 4410 | output = np.empty(1, dtype=float) |
| 4411 | output.fill(-9999) |
| 4412 | a.round(out=output) |
| 4413 | assert_equal(output, 1) |
| 4414 | |
| 4415 | a = array(1.1, mask=[False]) |
| 4416 | output = array(-9999., mask=[True]) |
| 4417 | a.round(out=output) |
| 4418 | assert_equal(output[()], 1) |
| 4419 | |
| 4420 | a = array(1.1, mask=[True]) |
| 4421 | output = array(-9999., mask=[False]) |
| 4422 | a.round(out=output) |
| 4423 | assert_(output[()] is masked) |
| 4424 | |
| 4425 | def test_identity(self): |
| 4426 | a = identity(5) |
nothing calls this directly
no test coverage detected