1
0
mirror of synced 2024-11-25 23:06:07 +03:00
api-client-php/tests/RetailCrm/Tests/Methods/Version4/ApiClientMarketplaceTest.php
2020-12-15 13:32:52 +03:00

48 lines
1.1 KiB
PHP

<?php
/**
* PHP version 5.4
*
* API client marketplace test class
*
* @category RetailCrm
* @package RetailCrm
*/
namespace RetailCrm\Tests\Methods\Version4;
use RetailCrm\Test\TestCase;
/**
* Class ApiClientMarketplaceTest
*
* @package RetailCrm\Tests
*/
class ApiClientMarketplaceTest extends TestCase
{
const SNAME = 'Marketplace integration v4';
const SCODE = 'integration_v4';
/**
* @group marketplace_v4
*/
public function testConfigurationEdit()
{
$client = static::getApiClient(null, null, "v4");
/* @var \RetailCrm\Response\ApiResponse $response */
$response = $client->request->marketplaceSettingsEdit(
[
'name' => self::SNAME,
'code' => self::SCODE,
'logo' => 'http://download.retailcrm.pro/logos/setup.svg',
'active' => 'true'
]
);
static::assertInstanceOf('RetailCrm\Response\ApiResponse', $response);
static::assertTrue(in_array($response->getStatusCode(), [200, 201]));
static::assertTrue($response->isSuccessful());
}
}