Neos\FluidAdaptor\Tests\Unit\ViewHelpers\TranslateViewHelperTest::translationFallbackTests PHP Method

translationFallbackTests() public method

public translationFallbackTests ( string $id, string $value, string $translatedId, string $translatedValue, string $expectedResult )
$id string
$value string
$translatedId string
$translatedValue string
$expectedResult string
    public function translationFallbackTests($id, $value, $translatedId, $translatedValue, $expectedResult)
    {
        $this->mockTranslator->expects($this->any())->method('translateById', $id)->will($this->returnValue($translatedId));
        $this->mockTranslator->expects($this->any())->method('translateByOriginalLabel', $value)->will($this->returnValue($translatedValue));
        $actualResult = $this->translateViewHelper->render($id, $value);
        $this->assertSame($expectedResult, $actualResult);
    }