Coverage for tests/numpy_mock.py: 82%
11 statements
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-09 04:47 +0000
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-09 04:47 +0000
1from __future__ import annotations
3from unittest.mock import MagicMock
6class NumPyMock(MagicMock):
7 @property
8 def __version__(self) -> str:
9 return "1.26.4"
11 @property
12 def __name__(self) -> str:
13 return "numpy"
15 def get_sub_modules(self) -> dict[str, MagicMock]:
16 return {
17 "numpy": self,
18 "numpy.typing": MagicMock(),
19 "numpy.core": MagicMock(),
20 "numpy.core.numeric": MagicMock(),
21 "numpy.linalg": MagicMock(),
22 }