use of org.omegat.filters2.moodlephp.MoodlePHPFilter in project omegat by omegat-org.
the class MoodlePHPFilterTest method testAlign.
@Test
public void testAlign() throws Exception {
final AlignResult ar = new AlignResult();
align(new MoodlePHPFilter(), "MoodlePHP/filesAlign.php", "MoodlePHP/filesAlign_gl.php", new IAlignCallback() {
public void addTranslation(String id, String source, String translation, boolean isFuzzy, String path, IFilter filter) {
ar.found = id.equals("access") && source.equals("Accessibility") && translation.equals("Accesibilidade");
}
});
assertTrue(ar.found);
}
use of org.omegat.filters2.moodlephp.MoodlePHPFilter in project omegat by omegat-org.
the class MoodlePHPFilterTest method testLoad.
@Test
public void testLoad() throws Exception {
String f = "test/data/filters/MoodlePHP/file.php";
IProject.FileInfo fi = loadSourceFiles(new MoodlePHPFilter(), f);
checkMultiStart(fi, f);
checkMulti("Accessibility", "access", null, null, null, null);
checkMulti("Accessibility help", "accesshelp", null, null, null, null);
checkMulti("Unrecognised options:\n" + " {$a}\n" + "Please use --help option.", "cliunknowoption", null, null, null, null);
checkMulti("You cannot uninstall the \\'{$a->filter}\\' because it is part of the \\'{$a->module}\\' module.", "cannotdeletemodfilter", null, null, null, null);
checkMulti("List of groups or contexts whose members are allowed to create attributes. Separate multiple groups with \\';\\'. Usually something like \\'cn=teachers,ou=staff,o=myorg\\'", "auth_ldap_attrcreators", null, null, null, null);
checkMultiEnd();
}
Aggregations