1
0
mirror of https://github.com/gnosygnu/xowa.git synced 2026-03-02 03:49:30 +00:00

'v3.7.1.1'

This commit is contained in:
gnosygnu
2016-07-03 22:41:56 -04:00
parent 1a4ca00c0b
commit 36584a0cc2
220 changed files with 4762 additions and 2627 deletions

View File

@@ -21,12 +21,14 @@ import gplx.xowa.langs.*; import gplx.xowa.langs.cases.*; import gplx.xowa.langs
import gplx.xowa.wikis.nss.*;
import gplx.xowa.parsers.paras.*; import gplx.xowa.wikis.ttls.*;
public class Xop_lnki_wkr__basic_tst {
@Before public void init() {fxt.Reset(); fxt.Init_para_n_();} private final Xop_fxt fxt = new Xop_fxt();
@Before public void init() {fxt.Reset(); fxt.Init_para_n_();} private final Xop_fxt fxt = new Xop_fxt();
@Test public void Basic() {
fxt.Test_parse_page_wiki("[[a]]", fxt.tkn_lnki_().Trg_tkn_(fxt.tkn_arg_val_txt_(2, 3)));
}
@Test public void HtmlRef() {
fxt.Test_parse_page_wiki("[[a&b]]", fxt.tkn_lnki_().Trg_tkn_(fxt.tkn_arg_nde_().Val_tkn_(fxt.tkn_arg_itm_(fxt.tkn_txt_(2, 3), fxt.tkn_html_ref_("&"), fxt.tkn_txt_(8, 9)))));
fxt.Test_parse_page_wiki_str("[[a&b]]"
, "<a href=\"/wiki/A%26b\">a&amp;b</a>"
);
}
@Test public void Url_encode() { // PURPOSE:title should automatically do url decoding; DATE:2013-08-26
fxt.Test_parse_page_all_str("[[A%20b]]", "<a href=\"/wiki/A_b\">A b</a>");