Extract a base test case, move mock config

This commit is contained in:
Oliver Davies 2020-05-30 13:40:52 +01:00
parent 79c4d9e5fd
commit 7162438837
2 changed files with 32 additions and 17 deletions

View 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();
}
}