1
0
mirror of synced 2024-12-01 09:06:04 +03:00
aliexpress-top-client/tests/RetailCrm/Tests/Builder/AuthorizationUriBuilderTest.php
2020-12-15 13:28:59 +03:00

33 lines
865 B
PHP

<?php
/**
* PHP version 7.3
*
* @category AuthorizationUriBuilderTest
* @package RetailCrm\Tests\Builder
*/
namespace RetailCrm\Tests\Builder;
use RetailCrm\Builder\AuthorizationUriBuilder;
use RetailCrm\Test\TestCase;
/**
* Class AuthorizationUriBuilderTest
*
* @category AuthorizationUriBuilderTest
* @package RetailCrm\Tests\Builder
*/
class AuthorizationUriBuilderTest extends TestCase
{
public function testBuild()
{
$appData = $this->getEnvAppData();
$builder = new AuthorizationUriBuilder($appData->getAppKey(), $appData->getRedirectUri(), 'state');
$result = $builder->build();
self::assertNotFalse(strpos($result, $appData->getAppKey()));
self::assertNotFalse(strpos($result, urlencode($appData->getRedirectUri())));
self::assertNotFalse(strpos($result, urlencode('state')));
}
}