mirror of
https://github.com/opdavies/glassboxx-sdk-php.git
synced 2025-02-17 22:50:48 +00:00
Extract a base test case, move mock config
This commit is contained in:
parent
79c4d9e5fd
commit
7162438837
2 changed files with 32 additions and 17 deletions
27
tests/Glassboxx/TestCase.php
Normal file
27
tests/Glassboxx/TestCase.php
Normal file
|
@ -0,0 +1,27 @@
|
|||
<?php
|
||||
|
||||
namespace Opdavies\Glassboxx\Tests\Glassboxx;
|
||||
|
||||
use Opdavies\Glassboxx\Config;
|
||||
|
||||
class TestCase extends \PHPUnit\Framework\TestCase
|
||||
{
|
||||
/** @var Config */
|
||||
protected $config;
|
||||
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
$this->config = $this->getMockBuilder(Config::class)
|
||||
->onlyMethods([])
|
||||
->setConstructorArgs(
|
||||
[
|
||||
'vendor_id' => 123,
|
||||
'username' => 'opdavies',
|
||||
'password' => 'secret',
|
||||
]
|
||||
)
|
||||
->getMock();
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue