def METHOD_NAME(self, input_param, input_data, _expected_shape):
    for p in TEST_NDARRAYS_ALL:
        input_param_mod = self.convert_data_type(p, input_param)
        input_data_mod = self.convert_data_type(p, input_data)
        cropper = RandCropByPosNegLabeld(**input_param_mod)
        # non-lazy
        cropper.set_random_state(0)
        expected = cropper(input_data_mod)
        self.assertIsInstance(expected[0]["image"], MetaTensor)
        # lazy
        cropper.set_random_state(0)
        cropper.lazy = True
        pending_result = cropper(input_data_mod)
        for i, _pending_result in enumerate(pending_result):
            self.assertIsInstance(_pending_result["image"], MetaTensor)
            assert_allclose(_pending_result["image"].peek_pending_affine(), expected[i]["image"].affine)
            assert_allclose(_pending_result["image"].peek_pending_shape(), expected[i]["image"].shape[1:])
            # only support nearest
            overrides = {"mode": "nearest", "align_corners": False}
            result_image = apply_pending(_pending_result["image"], overrides=overrides)[0]
            result_extra = apply_pending(_pending_result["extra"], overrides=overrides)[0]
            # compare
            assert_allclose(result_image, expected[i]["image"], rtol=1e-5)
            assert_allclose(result_extra, expected[i]["extra"], rtol=1e-5)