Skip to content

Commit 9c4c61d

Browse files
committed
MC-18009: Disabled Products Do Not Appear in Search Results of Link Attribute
- update tests
1 parent cf9e61f commit 9c4c61d

File tree

1 file changed

+3
-3
lines changed
  • dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/Product

1 file changed

+3
-3
lines changed

dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/Product/SearchTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public function testExecuteNonExistingSearchKey() : void
3838
->setPostValue('limit', 50);
3939
$this->dispatch('backend/catalog/product/search');
4040
$responseBody = $this->getResponse()->getBody();
41-
$jsonResponse = json_decode($responseBody);
41+
$jsonResponse = json_decode($responseBody, true);
4242
$this->assertEmpty($jsonResponse['options']);
4343
}
4444

@@ -58,7 +58,7 @@ public function testExecuteNotVisibleIndividuallyProducts() : void
5858
->setPostValue('limit', 50);
5959
$this->dispatch('backend/catalog/product/search');
6060
$responseBody = $this->getResponse()->getBody();
61-
$jsonResponse = json_decode($responseBody);
61+
$jsonResponse = json_decode($responseBody, true);
6262
$this->assertEquals(1, $jsonResponse['total']);
6363
$this->assertCount(1, $jsonResponse['options']);
6464
}
@@ -74,7 +74,7 @@ public function testExecuteEnabledAndDisabledProducts() : void
7474
->setPostValue('limit', 50);
7575
$this->dispatch('backend/catalog/product/search');
7676
$responseBody = $this->getResponse()->getBody();
77-
$jsonResponse = json_decode($responseBody);
77+
$jsonResponse = json_decode($responseBody, true);
7878
$this->assertEquals(7, $jsonResponse['total']);
7979
$this->assertCount(7, $jsonResponse['options']);
8080
}

0 commit comments

Comments
 (0)