diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/Notification/ManagerTest.php | 4 | ||||
-rw-r--r-- | tests/lib/RichObjectStrings/ValidatorTest.php | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/tests/lib/Notification/ManagerTest.php b/tests/lib/Notification/ManagerTest.php index 4410781bc31..e280838424b 100644 --- a/tests/lib/Notification/ManagerTest.php +++ b/tests/lib/Notification/ManagerTest.php @@ -23,6 +23,7 @@ namespace Test\Notification; use OC\Notification\Manager; use OCP\Notification\IManager; +use OCP\RichObjectStrings\IValidator; use Test\TestCase; class ManagerTest extends TestCase { @@ -31,7 +32,8 @@ class ManagerTest extends TestCase { public function setUp() { parent::setUp(); - $this->manager = new Manager(); + $validator = $this->createMock(IValidator::class); + $this->manager = new Manager($validator); } public function testRegisterApp() { diff --git a/tests/lib/RichObjectStrings/ValidatorTest.php b/tests/lib/RichObjectStrings/ValidatorTest.php index b97388ab8e0..f18d1bdd908 100644 --- a/tests/lib/RichObjectStrings/ValidatorTest.php +++ b/tests/lib/RichObjectStrings/ValidatorTest.php @@ -23,12 +23,13 @@ namespace Test\RichObjectStrings; use OC\RichObjectStrings\Validator; +use OCP\RichObjectStrings\Definitions; use Test\TestCase; class ValidatorTest extends TestCase { public function test() { - $v = new Validator(); + $v = new Validator(new Definitions()); $v->validate('test', []); $v->validate('test {string1} test {foo} test {bar}.', [ 'string1' => [ |