(self)
| 2852 | assert_identical(expected_y2, actual_y2) |
| 2853 | |
| 2854 | def test_broadcast_nocopy(self) -> None: |
| 2855 | # Test that data is not copied if not needed |
| 2856 | x = Dataset({"foo": (("x", "y"), [[1, 1]])}) |
| 2857 | y = Dataset({"bar": ("y", [2, 3])}) |
| 2858 | |
| 2859 | (actual_x,) = broadcast(x) |
| 2860 | assert_identical(x, actual_x) |
| 2861 | assert source_ndarray(actual_x["foo"].data) is source_ndarray(x["foo"].data) |
| 2862 | |
| 2863 | actual_x, _actual_y = broadcast(x, y) |
| 2864 | assert_identical(x, actual_x) |
| 2865 | assert source_ndarray(actual_x["foo"].data) is source_ndarray(x["foo"].data) |
| 2866 | |
| 2867 | def test_broadcast_exclude(self) -> None: |
| 2868 | x = Dataset( |
nothing calls this directly
no test coverage detected