Skip to content

Commit 219a7e6

Browse files
committed
added test #263
1 parent cdaae2f commit 219a7e6

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

tests/PoLoaderTest.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -258,4 +258,22 @@ public function testStringDecode($source, $decoded)
258258
{
259259
$this->assertSame($decoded, PoLoader::decode($source));
260260
}
261+
262+
public function testMultilineDisabledTranslations() {
263+
$po = <<<EOT
264+
#~ msgid "Last agent hours-description"
265+
#~ msgstr ""
266+
#~ "How many hours in the past can system look at finding the last agent? "
267+
#~ "This parameter is only used if 'Call Last Agent' is set to 'YES'."
268+
EOT;
269+
$loader = new PoLoader();
270+
$translations = $loader->loadString($po);
271+
$translation = $translations->find(null, 'Last agent hours-description');
272+
273+
$this->assertTrue($translation->isDisabled());
274+
$this->assertEquals(
275+
"How many hours in the past can system look at finding the last agent? This parameter is only used if 'Call Last Agent' is set to 'YES'.",
276+
$translation->getTranslation()
277+
);
278+
}
261279
}

0 commit comments

Comments
 (0)