Showing the changes to python/tests (1 of 2 files). Show all
Unified · Split
| @@ -60,6 +60,14 @@ class aubio_fvec_wrong_values(TestCase): · 59 unmodified lines | ||
| 60 | 60 | self.assertRaises(IndexError, a.__getitem__, 3) |
| 61 | 61 | self.assertRaises(IndexError, a.__getitem__, 2) |
| 62 | 62 | |
| 63 | + def test_wrong_dimensions(self): | |
| 64 | + a = np.array([[[1, 2], [3, 4]]], dtype=float_type) | |
| 65 | + self.assertRaises(ValueError, fvec, a) | |
| 66 | + | |
| 67 | + def test_wrong_size(self): | |
| 68 | + a = np.ndarray([0,], dtype=float_type) | |
| 69 | + self.assertRaises(ValueError, fvec, a) | |
| 70 | + | |
| 63 | 71 | class aubio_wrong_fvec_input(TestCase): |
| 64 | 72 | """ uses min_removal to test PyAubio_IsValidVector """ |
| 65 | 73 | |