1,
new ProductReviewCollection([$productReview]),
null,
new Criteria(),
Context::
createDefaultContext() );
$this->productReviewLoaderMock->
method('load'
)->
with( $request,
$this->
createMock(SalesChannelContext::
class) )->
willReturn($reviewResult);
$response =
$this->controller->
loadReviews( $request,
$requestBag,
$this->
createMock(SalesChannelContext::
class) );
static::
assertEquals(Response::HTTP_OK,
$response->
getStatusCode());
static::
assertEquals('storefront/page/product-detail/review/review.html.twig',
$this->controller->renderStorefrontView
);
static::
assertEquals( [ 'reviews' =>
$reviewResult,
'ratingSuccess' => null,
],