TC-UNPUB-02
Negative
Validation
changes data Unpublish an already inactive product
Verify system behavior when the product is already inactive
! Documented discrepancy · errors.txt
The invalid data has no effect on the system response and still leads to code 200 instead of 400.
Specification · xlsx
Steps
- Send an unpublish request for an already inactive product
Expected result
Not specified in the spreadsheet.
Endpoints
POST /product/api/v1/merchant-integration/product/publishPOST /product/api/v1/merchant-integration/product/unpublish Run
- API_URL
https://api.qa2.ananastest.com- TARGET_ID
2555660
A dry run builds every request without sending it; responses come from a local stub.
Test code
mirrors tests/PublishTest.php::tc_unpub_02()
51// Verify system behavior when the product is already inactive
52public function tc_unpub_02(): void
53{
54 $targetId = $_ENV['TARGET_ID'];
55
56 $response = $this->ananas->unpublish([$targetId]);
57
58 $this->assertEquals(400, $response['statusCode']);
59}
web/app/Scenarios/PublishScenarios.php · line numbers refer to this file
Not run yet. Run it against the API, or do a dry run to see the requests it would send.