/** * Tests the __n() function * * @return void */ public function testBasicTranslatePluralFunction() { I18n::defaultFormatter('sprintf'); $result = __n('singular msg', '%d = 0 or > 1', 1); $this->assertEquals('1 is 1 (po translated)', $result); $result = __n('singular msg', '%d = 0 or > 1', 2); $this->assertEquals('2 is 2-4 (po translated)', $result); }