mirror of
https://github.com/bitinflow/accounts.git
synced 2026-03-13 13:35:52 +00:00
Add methods to change base url
This commit is contained in:
@@ -45,7 +45,7 @@ class ApiDocumentsTest extends ApiTestCase
|
||||
|
||||
$expiresAt = now()->addHours(2);
|
||||
|
||||
$result = $this->getClient()->createDocumentDownloadUrl(1, $expiresAt);
|
||||
$result = $this->getClient()->createDocumentDownloadUrl('1', $expiresAt);
|
||||
|
||||
$this->registerResult($result);
|
||||
$this->assertTrue($result->success());
|
||||
|
||||
@@ -18,6 +18,11 @@ abstract class ApiTestCase extends TestCase
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
if ($this->getBaseUrl()) {
|
||||
BitinflowAccounts::setBaseUrl($this->getBaseUrl());
|
||||
}
|
||||
|
||||
if (!$this->getClientId()) {
|
||||
$this->markTestSkipped('No Client-ID given');
|
||||
}
|
||||
@@ -34,6 +39,11 @@ abstract class ApiTestCase extends TestCase
|
||||
return $result;
|
||||
}
|
||||
|
||||
protected function getBaseUrl()
|
||||
{
|
||||
return getenv('BASE_URL');
|
||||
}
|
||||
|
||||
protected function getClientId()
|
||||
{
|
||||
return getenv('CLIENT_ID');
|
||||
|
||||
Reference in New Issue
Block a user