1<?php 2 3/** 4 * This file is part of the Phalcon Framework. 5 * 6 * (c) Phalcon Team <team@phalcon.io> 7 * 8 * For the full copyright and license information, please view the LICENSE.txt 9 * file that was distributed with this source code. 10 */ 11 12declare(strict_types=1); 13 14namespace Phalcon\Test\Unit\Translate\Adapter\Gettext; 15 16use Phalcon\Test\Fixtures\Traits\TranslateGettextTrait; 17use Phalcon\Translate\Adapter\Gettext; 18use Phalcon\Translate\InterpolatorFactory; 19use UnitTester; 20 21class NqueryCest 22{ 23 use TranslateGettextTrait; 24 25 /** 26 * Tests Phalcon\Translate\Adapter\Gettext :: nquery() 27 * 28 * @author Phalcon Team <team@phalcon.io> 29 * @since 2018-11-13 30 */ 31 public function translateAdapterGettextNquery(UnitTester $I) 32 { 33 $I->wantToTest('Translate\Adapter\Gettext - nquery()'); 34 35 $params = $this->getGettextConfig(); 36 $translator = new Gettext( 37 new InterpolatorFactory(), 38 $params 39 ); 40 41 $I->assertEquals('two files', $translator->nquery('file', 'files', 2)); 42 } 43} 44