diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Catalog/MediaGalleryTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Catalog/MediaGalleryTest.php index 8da2702917af0..38ba4760e93a3 100644 --- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Catalog/MediaGalleryTest.php +++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Catalog/MediaGalleryTest.php @@ -45,6 +45,33 @@ public function testProductSmallImageUrlWithExistingImage() self::assertTrue($this->checkImageExists($response['products']['items'][0]['small_image']['url'])); } + /** + * @magentoApiDataFixture Magento/Catalog/_files/product_with_image.php + */ + public function testProductMediaGalleryEntries() + { + $productSku = 'simple'; + $query = <<graphQlQuery($query); + + self::assertArrayHasKey('file', $response['products']['items'][0]['media_gallery_entries'][0]); + self::assertContains('magento_image.jpg', $response['products']['items'][0]['media_gallery_entries'][0]['url']); + } + /** * @param string $url * @return bool