Fix getMock Security
This commit is contained in:
parent
dc60f4c441
commit
e1096c964d
2 changed files with 4 additions and 4 deletions
|
@ -44,9 +44,9 @@ class ThrottlerTest extends TestCase {
|
|||
private $config;
|
||||
|
||||
public function setUp() {
|
||||
$this->dbConnection = $this->getMock('\OCP\IDBConnection');
|
||||
$this->logger = $this->getMock('\OCP\ILogger');
|
||||
$this->config = $this->getMock('\OCP\IConfig');
|
||||
$this->dbConnection = $this->createMock(IDBConnection::class);
|
||||
$this->logger = $this->createMock(ILogger::class);
|
||||
$this->config = $this->createMock(IConfig::class);
|
||||
|
||||
$this->throttler = new Throttler(
|
||||
$this->dbConnection,
|
||||
|
|
|
@ -38,7 +38,7 @@ class CredentialsManagerTest extends \Test\TestCase {
|
|||
|
||||
protected function setUp() {
|
||||
parent::setUp();
|
||||
$this->crypto = $this->getMock('\OCP\Security\ICrypto');
|
||||
$this->crypto = $this->createMock(ICrypto::class);
|
||||
$this->dbConnection = $this->getMockBuilder('\OC\DB\Connection')
|
||||
->disableOriginalConstructor()
|
||||
->getMock();
|
||||
|
|
Loading…
Reference in a new issue