Validate basic `read` functionality.
(self, vs_type: ty.Callable[..., VideoStream], test_video: VideoParameters)
| 154 | ) |
| 155 | |
| 156 | def test_read(self, vs_type: ty.Callable[..., VideoStream], test_video: VideoParameters): |
| 157 | """Validate basic `read` functionality.""" |
| 158 | stream = vs_type(test_video.path) |
| 159 | frame = stream.read() |
| 160 | assert isinstance(frame, numpy.ndarray) |
| 161 | # For now hard-code 3 channels/pixel for each test video |
| 162 | assert frame.shape == (test_video.height, test_video.width, 3) |
| 163 | assert stream.frame_number == 1 |
| 164 | |
| 165 | def test_read_no_decode( |
| 166 | self, vs_type: ty.Callable[..., VideoStream], test_video: VideoParameters |