public function TranslationRequestsApiFunctionalTest::setUp in TMGMT Translator Smartling 8.3
Same name and namespace in other branches
- 8.4 vendor/smartling/api-sdk-php/tests/functional/TranslationRequestsApiFunctionalTest.php \Smartling\Tests\Unit\TranslationRequestsApiFunctionalTest::setUp()
Test mixture.
File
- vendor/
smartling/ api-sdk-php/ tests/ functional/ TranslationRequestsApiFunctionalTest.php, line 23
Class
Namespace
Smartling\Tests\UnitCode
public function setUp() {
$projectId = getenv('project_id');
$userIdentifier = getenv('user_id');
$userSecretKey = getenv('user_key');
if (empty($projectId) || empty($userIdentifier) || empty($userSecretKey)) {
$this
->fail('Missing required parameters');
}
$authProvider = AuthTokenProvider::create($userIdentifier, $userSecretKey);
$this->translationRequestsApi = TranslationRequestsApi::create($authProvider, $projectId);
}