]> git.mxchange.org Git - friendica.git/blobdiff - tests/Util/AppMockTrait.php
Fixing issue L10n::t()
[friendica.git] / tests / Util / AppMockTrait.php
index cdd5aedd5d890a733ec64a0b8e8272422827fae5..72c0dc429bf0035764338744c390f4335b64edcf 100644 (file)
@@ -27,10 +27,10 @@ trait AppMockTrait
         */
        public function mockApp($root)
        {
-               /// @todo This mock is ugly. We return an empty string for each translation - no workaround yet
+               // simply returning the input when using L10n::t()
                $l10nMock = \Mockery::mock('alias:Friendica\Core\L10n');
                $l10nMock->shouldReceive('t')
-                       ->andReturn('');
+                       ->andReturnUsing(function ($arg) { return $arg; });
 
                $this->mockConfigGet('system', 'theme', 'testtheme');