mirror of
https://github.com/gnosygnu/xowa.git
synced 2026-03-02 03:49:30 +00:00
Refactor: @Test whitespace clean-up and other corelib changes
This commit is contained in:
@@ -1,28 +1,28 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*; import gplx.core.stores.*;
|
||||
public class GfmlDataRdr_tst {
|
||||
@Test public void Raw() {
|
||||
@Test public void Raw() {
|
||||
raw = "root:{}";
|
||||
rdr = rdr_(raw);
|
||||
|
||||
Tfds.Eq(rdr.NameOfNode(), "root");
|
||||
}
|
||||
@Test public void Atrs() {
|
||||
@Test public void Atrs() {
|
||||
raw = "root:id=1 name=me isPresent=true dateOf='2006-12-08';";
|
||||
rdr = rdr_(raw);
|
||||
|
||||
@@ -31,7 +31,7 @@ public class GfmlDataRdr_tst {
|
||||
Tfds.Eq(rdr.ReadBool("isPresent"), true);
|
||||
Tfds.Eq_date(rdr.ReadDate("dateOf"), DateAdp_.parse_gplx("2006-12-08"));
|
||||
}
|
||||
@Test public void Subs() {
|
||||
@Test public void Subs() {
|
||||
raw = String_.Concat_any(
|
||||
"root:{",
|
||||
" computers:id=1 {",
|
||||
@@ -63,7 +63,7 @@ public class GfmlDataRdr_tst {
|
||||
}
|
||||
Tfds.Eq(idx, 2);
|
||||
}
|
||||
@Test public void SelectRdr() {
|
||||
@Test public void SelectRdr() {
|
||||
raw = String_.Concat_any(
|
||||
"root:{",
|
||||
" person:name=me {}",
|
||||
@@ -78,7 +78,7 @@ public class GfmlDataRdr_tst {
|
||||
Tfds.Eq(computer.NameOfNode(), "computer");
|
||||
Tfds.Eq(computer.ReadStr("brand"), "noname");
|
||||
}
|
||||
// @Test public void Subs_byKey() {
|
||||
// @Test public void Subs_byKey() {
|
||||
// raw = String_.Concat_any(
|
||||
// "root:",
|
||||
// " person=(name=me)",
|
||||
@@ -89,7 +89,7 @@ public class GfmlDataRdr_tst {
|
||||
// Tfds.Eq(person.NameOfNode, "person");
|
||||
// Tfds.Eq(person.ReadStr("name"), "me");
|
||||
// }
|
||||
// @Test public void Type() {
|
||||
// @Test public void Type() {
|
||||
// raw = String_.Concat_any(
|
||||
// "root:{",
|
||||
// " _type:{example{explicit_val; bool_val; int_val; string_val; long_val; date_val; float_val; decimal_val;}}",
|
||||
|
||||
@@ -1,42 +1,42 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z011_IntObjHash_tst {
|
||||
public class z011_IntObjHash_tst {
|
||||
@Before public void setup() {
|
||||
hash = new IntObjHash_base();
|
||||
} IntObjHash_base hash;
|
||||
@Test public void Empty() {
|
||||
@Test public void Empty() {
|
||||
tst_Count(0);
|
||||
tst_Fetch(1, null);
|
||||
}
|
||||
@Test public void Add() {
|
||||
@Test public void Add() {
|
||||
hash.Add(1, "1");
|
||||
tst_Count(1);
|
||||
tst_Fetch(1, "1");
|
||||
tst_Fetch(2, null);
|
||||
}
|
||||
@Test public void Del() {
|
||||
@Test public void Del() {
|
||||
hash.Add(1, "1");
|
||||
|
||||
hash.Del(1);
|
||||
tst_Count(0);
|
||||
tst_Fetch(1, null);
|
||||
}
|
||||
@Test public void Clear() {
|
||||
@Test public void Clear() {
|
||||
hash.Add(1, "1");
|
||||
hash.Add(32, "32");
|
||||
tst_Fetch(1, "1");
|
||||
@@ -48,7 +48,7 @@ public class z011_IntObjHash_tst {
|
||||
tst_Fetch(2, null);
|
||||
tst_Fetch(32, null);
|
||||
}
|
||||
@Test public void Add_bug() { // fails after expanding ary, and fetching at key=n*16
|
||||
@Test public void Add_bug() { // fails after expanding ary, and fetching at key=n*16
|
||||
hash.Add(1, "1");
|
||||
tst_Count(1);
|
||||
tst_Fetch(1, "1");
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
import gplx.core.texts.*; /*CharStream*/
|
||||
@@ -20,28 +20,28 @@ public class z012_GfmlTrie_tst {
|
||||
@Before public void setup() {
|
||||
trie = GfmlTrie.new_();
|
||||
} GfmlTrie trie;
|
||||
@Test public void Null() {
|
||||
@Test public void Null() {
|
||||
tst_FindMatch_first("", null);
|
||||
tst_FindMatch_first("{", null);
|
||||
}
|
||||
@Test public void OneChar() {
|
||||
@Test public void OneChar() {
|
||||
trie.Add("{", "val0");
|
||||
tst_FindMatch_first("{", "val0");
|
||||
tst_FindMatch_first(":", null);
|
||||
}
|
||||
@Test public void TwoChar() {
|
||||
@Test public void TwoChar() {
|
||||
trie.Add("/*", "val0");
|
||||
tst_FindMatch_first("/*", "val0");
|
||||
tst_FindMatch_first("//", null);
|
||||
}
|
||||
@Test public void ManySym() {
|
||||
@Test public void ManySym() {
|
||||
trie.Add(":", "val0");
|
||||
trie.Add("{", "val1");
|
||||
tst_FindMatch_first(":", "val0");
|
||||
tst_FindMatch_first("{", "val1");
|
||||
tst_FindMatch_first("-", null);
|
||||
}
|
||||
@Test public void Overlap_1_2() {
|
||||
@Test public void Overlap_1_2() {
|
||||
trie.Add("[", "val0");
|
||||
trie.Add("[:", "val1");
|
||||
tst_FindMatch_first("[", "val0");
|
||||
@@ -49,7 +49,7 @@ public class z012_GfmlTrie_tst {
|
||||
tst_FindMatch_first("[-", "val0");
|
||||
tst_FindMatch_first(":", null);
|
||||
}
|
||||
@Test public void Overlap_2_1() {
|
||||
@Test public void Overlap_2_1() {
|
||||
trie.Add("[:", "val0");
|
||||
trie.Add("[", "val1");
|
||||
tst_FindMatch_first("[:", "val0");
|
||||
@@ -57,7 +57,7 @@ public class z012_GfmlTrie_tst {
|
||||
tst_FindMatch_first("[-", "val1");
|
||||
tst_FindMatch_first(":", null);
|
||||
}
|
||||
@Test public void Overlap_1_1() {
|
||||
@Test public void Overlap_1_1() {
|
||||
trie.Add("[", "val0");
|
||||
trie.Add("[", "val1");
|
||||
tst_FindMatch_first("[", "val1"); // return last added
|
||||
|
||||
@@ -1,45 +1,45 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z015_GfmlDocPos_tst {
|
||||
public class z015_GfmlDocPos_tst {
|
||||
GfmlDocPos root = GfmlDocPos_.Root;
|
||||
@Test public void Root() {
|
||||
@Test public void Root() {
|
||||
tst_Path(root, "0");
|
||||
}
|
||||
@Test public void MoveDown() {
|
||||
@Test public void MoveDown() {
|
||||
tst_Path(root.NewDown(0), "0_0");
|
||||
tst_Path(root.NewDown(0).NewDown(0), "0_0_0");
|
||||
tst_Path(root.NewDown(1).NewDown(2), "0_1_2");
|
||||
}
|
||||
@Test public void MoveUp() {
|
||||
@Test public void MoveUp() {
|
||||
tst_Path(root.NewDown(1).NewDown(2).NewUp(), "0_1");
|
||||
}
|
||||
@Test public void CompareTo_same() {
|
||||
@Test public void CompareTo_same() {
|
||||
GfmlDocPos lhs = root.NewDown(0);
|
||||
GfmlDocPos rhs = root.NewDown(0);
|
||||
tst_CompareTo(lhs, rhs, CompareAble_.Same);
|
||||
}
|
||||
@Test public void CompareTo_diffIndex() {
|
||||
@Test public void CompareTo_diffIndex() {
|
||||
GfmlDocPos lhs = root.NewDown(0);
|
||||
GfmlDocPos rhs = root.NewDown(1);
|
||||
tst_CompareTo(lhs, rhs, CompareAble_.Less);
|
||||
tst_CompareTo(rhs, lhs, CompareAble_.More);
|
||||
}
|
||||
@Test public void CompareTo_diffLevel() {
|
||||
@Test public void CompareTo_diffLevel() {
|
||||
GfmlDocPos lhs = root;
|
||||
GfmlDocPos rhs = root.NewDown(0);
|
||||
tst_CompareTo(lhs, rhs, CompareAble_.Less);
|
||||
|
||||
@@ -1,32 +1,32 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z016_GfmlScopeList_tst {
|
||||
@Before public void setup() {
|
||||
list = GfmlScopeList.new_("test");
|
||||
} GfmlScopeList list;
|
||||
@Test public void None() {
|
||||
@Test public void None() {
|
||||
tst_Itm(list, GfmlDocPos_.Root, null);
|
||||
}
|
||||
@Test public void One() {
|
||||
@Test public void One() {
|
||||
run_Add(list, var_("val1"));
|
||||
tst_Itm(list, GfmlDocPos_.Root, "val1");
|
||||
}
|
||||
@Test public void ByPos() {
|
||||
@Test public void ByPos() {
|
||||
run_Add(list, var_("val1").DocPos_(docPos_(0, 0)));
|
||||
run_Add(list, var_("val2").DocPos_(docPos_(0, 0, 0)));
|
||||
tst_Itm(list, docPos_(0, 0), "val1");
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z017_GfmlStringHighlighter_tst {
|
||||
@Test public void Short() {
|
||||
@Test public void Short() {
|
||||
tst_Err(sh_().Raw_("a=").Mark_(1, '=', "key tkn").Mark_(2, '?', "EOS:missing data")
|
||||
, "< >"
|
||||
, " a= "
|
||||
@@ -26,14 +26,14 @@ public class z017_GfmlStringHighlighter_tst {
|
||||
, "[2] ? EOS:missing data"
|
||||
);
|
||||
}
|
||||
@Test public void Whitespace() {
|
||||
@Test public void Whitespace() {
|
||||
tst_Err(sh_().Raw_("a\t\nb").Mark_(0, ' ', "")
|
||||
, "< tn >"
|
||||
, " a b "
|
||||
, " "
|
||||
);
|
||||
}
|
||||
@Test public void Long() {
|
||||
@Test public void Long() {
|
||||
tst_Err(sh_().Raw_("abcdefghijklmnopqrstuvwxyzyxwvutsrqponmlkjihgfedcba").Mark_(0, '{', "bgn").Mark_(50, '}', "end")
|
||||
, "< >"
|
||||
, " abcdefghijklmnopqrstuvwxyzyxwvutsrqponmlkjihgfedcba "
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z051_GfmlFldPool_keyed_tst {
|
||||
@@ -21,26 +21,26 @@ public class z051_GfmlFldPool_keyed_tst {
|
||||
GfmlType type = makr.MakeSubType("point", "x", "y", "z");
|
||||
fldPool = GfmlFldPool.new_(type);
|
||||
} GfmlFldPool fldPool;
|
||||
@Test public void PopByKey_inOrder() {
|
||||
@Test public void PopByKey_inOrder() {
|
||||
tst_Keyed_PopByKey(fldPool, "x", "x", "y", "z");
|
||||
}
|
||||
@Test public void PopByKey_outOfOrder() {
|
||||
@Test public void PopByKey_outOfOrder() {
|
||||
tst_Keyed_PopByKey(fldPool, "y", "y", "x", "z");
|
||||
}
|
||||
@Test public void PopByKey_unknown() {
|
||||
@Test public void PopByKey_unknown() {
|
||||
tst_Keyed_PopByKey(fldPool, "a", GfmlItmKeys.NullKey, "x", "y", "z");
|
||||
}
|
||||
@Test public void PopByKey_alreadyRemoved() {
|
||||
@Test public void PopByKey_alreadyRemoved() {
|
||||
tst_Keyed_PopByKey(fldPool, "x", "x", "y", "z");
|
||||
tst_Keyed_PopByKey(fldPool, "x", GfmlItmKeys.NullKey, "y", "z");
|
||||
}
|
||||
@Test public void PopByKey_depleted() {
|
||||
@Test public void PopByKey_depleted() {
|
||||
tst_Keyed_PopByKey(fldPool, "x", "x", "y", "z");
|
||||
tst_Keyed_PopByKey(fldPool, "y", "y", "z");
|
||||
tst_Keyed_PopByKey(fldPool, "z", "z");
|
||||
tst_Keyed_PopByKey(fldPool, "x", GfmlItmKeys.NullKey);
|
||||
}
|
||||
@Test public void PopNext_inOrder() {
|
||||
@Test public void PopNext_inOrder() {
|
||||
tst_Keyed_PopNext(fldPool, "x", "y", "z");
|
||||
tst_Keyed_PopNext(fldPool, "y", "z");
|
||||
tst_Keyed_PopNext(fldPool, "z");
|
||||
@@ -50,7 +50,7 @@ public class z051_GfmlFldPool_keyed_tst {
|
||||
}
|
||||
catch (Exception exc) {Err_.Noop(exc);}
|
||||
}
|
||||
@Test public void PopByKey_PopNext() {
|
||||
@Test public void PopByKey_PopNext() {
|
||||
tst_Keyed_PopByKey(fldPool, "y", "y", "x", "z");
|
||||
tst_Keyed_PopNext(fldPool, "x", "z");
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*; import gplx.core.stores.*;
|
||||
public class z081_GfmlDataWtr_tst {
|
||||
@@ -20,45 +20,45 @@ public class z081_GfmlDataWtr_tst {
|
||||
wtr = GfmlDataWtr.new_();
|
||||
wtr.WriteNodeBgn("root");
|
||||
} DataWtr wtr;
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
tst_XtoStr(wtr, "root:;");
|
||||
}
|
||||
@Test public void Atr_one() {
|
||||
@Test public void Atr_one() {
|
||||
wtr.WriteData("key", "data");;
|
||||
tst_XtoStr(wtr, "root:key='data';");
|
||||
}
|
||||
@Test public void Atr_many() {
|
||||
@Test public void Atr_many() {
|
||||
wtr.WriteData("key1", "data1");
|
||||
wtr.WriteData("key2", "data2");
|
||||
tst_XtoStr(wtr, "root:key1='data1' key2='data2';");
|
||||
}
|
||||
@Test public void Nde_one() {
|
||||
@Test public void Nde_one() {
|
||||
wtr.WriteNodeBgn("sub0");
|
||||
tst_XtoStr(wtr, "root:{sub0:;}");
|
||||
}
|
||||
@Test public void Nde_many() {
|
||||
@Test public void Nde_many() {
|
||||
wtr.WriteNodeBgn("sub0");
|
||||
wtr.WriteNodeEnd();
|
||||
wtr.WriteNodeBgn("sub1");
|
||||
tst_XtoStr(wtr, "root:{sub0:;sub1:;}");
|
||||
}
|
||||
@Test public void Nde_nested() {
|
||||
@Test public void Nde_nested() {
|
||||
wtr.WriteNodeBgn("sub0");
|
||||
wtr.WriteNodeBgn("sub1");
|
||||
tst_XtoStr(wtr, "root:{sub0:{sub1:;}}");
|
||||
}
|
||||
@Test public void OneAtrOneNde() {
|
||||
@Test public void OneAtrOneNde() {
|
||||
wtr.WriteData("key1", "data1");
|
||||
wtr.WriteNodeBgn("sub0");
|
||||
tst_XtoStr(wtr, "root:key1='data1'{sub0:;}");
|
||||
}
|
||||
@Test public void OneAtrOneNdeOneAtr() {
|
||||
@Test public void OneAtrOneNdeOneAtr() {
|
||||
wtr.WriteData("key1", "data1");
|
||||
wtr.WriteNodeBgn("sub0");
|
||||
wtr.WriteData("key2", "data2");
|
||||
tst_XtoStr(wtr, "root:key1='data1'{sub0:key2='data2';}");
|
||||
}
|
||||
@Test public void EscapeQuote() {
|
||||
@Test public void EscapeQuote() {
|
||||
wtr.WriteData("key", "data's");;
|
||||
tst_XtoStr(wtr, "root:key='data''s';");
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*; import gplx.core.stores.*;
|
||||
public class z082_GfmlDataWtrOpts_tst {
|
||||
@@ -20,13 +20,13 @@ public class z082_GfmlDataWtrOpts_tst {
|
||||
wtr = GfmlDataWtr.new_();
|
||||
wtr.WriteNodeBgn("root");
|
||||
} DataWtr wtr;
|
||||
@Test public void KeyedSpr() {
|
||||
@Test public void KeyedSpr() {
|
||||
wtr.InitWtr(GfmlDataWtrOpts.Key_const, GfmlDataWtrOpts.new_().KeyedSeparator_("\t"));
|
||||
wtr.WriteData("key1", "data1");
|
||||
wtr.WriteData("key2", "data2");
|
||||
tst_XtoStr(wtr, "root:key1='data1'\tkey2='data2';");
|
||||
}
|
||||
@Test public void IndentNamesOn() {
|
||||
@Test public void IndentNamesOn() {
|
||||
wtr.InitWtr(GfmlDataWtrOpts.Key_const, GfmlDataWtrOpts.new_().IndentNodesOn_());
|
||||
wtr.WriteNodeBgn("nde1");
|
||||
wtr.WriteNodeBgn("nde2");
|
||||
@@ -39,7 +39,7 @@ public class z082_GfmlDataWtrOpts_tst {
|
||||
, "}"
|
||||
));
|
||||
}
|
||||
@Test public void IgnoreNullNamesOn() {
|
||||
@Test public void IgnoreNullNamesOn() {
|
||||
wtr.InitWtr(GfmlDataWtrOpts.Key_const, GfmlDataWtrOpts.new_().IgnoreNullNamesOn_());
|
||||
wtr.WriteNodeBgn("");
|
||||
wtr.WriteData("key1", "data1");
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
import gplx.core.texts.*; /*CharStream*/
|
||||
@@ -20,20 +20,20 @@ public class z091_GfmlLxr_basic_tst {
|
||||
@Before public void setup() {
|
||||
rootLxr = GfmlLxr_.general_("gfml.root", GfmlTkn_.cmd_("tkn:text", GfmlBldrCmd_.Null));
|
||||
} GfmlLxr rootLxr;
|
||||
@Test public void Empty() {
|
||||
@Test public void Empty() {
|
||||
tst_Fetch("");
|
||||
}
|
||||
@Test public void General() {
|
||||
@Test public void General() {
|
||||
tst_Fetch("text", "text");
|
||||
}
|
||||
@Test public void Solo() {
|
||||
@Test public void Solo() {
|
||||
ini_AddSymbol(",");
|
||||
tst_Fetch(",", ",");
|
||||
tst_Fetch(",data0", ",", "data0");
|
||||
tst_Fetch("data0,", "data0", ",");
|
||||
tst_Fetch("data0,data1", "data0", ",", "data1");
|
||||
}
|
||||
@Test public void Range() {
|
||||
@Test public void Range() {
|
||||
ini_AddRange(" ", "\t");
|
||||
tst_Fetch(" ", " ");
|
||||
tst_Fetch(" a", " ", "a");
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z101_core_ndeInline_tst {
|
||||
@@ -20,7 +20,7 @@ public class z101_core_ndeInline_tst {
|
||||
@Before public void setup() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.NdeInline_lxr());
|
||||
}
|
||||
@Test public void One() {
|
||||
@Test public void One() {
|
||||
fx.tst_Doc("a;", fx.nde_().Atru_("a"));
|
||||
fx.tst_Tkn("a;"
|
||||
, fx.tkn_grp_
|
||||
@@ -28,7 +28,7 @@ public class z101_core_ndeInline_tst {
|
||||
, fx.tkn_itm_(";")
|
||||
));
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Doc("a;b;"
|
||||
, fx.nde_().Atru_("a")
|
||||
, fx.nde_().Atru_("b")
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z102_core_whitespace_tst {
|
||||
@@ -23,7 +23,7 @@ public class z102_core_whitespace_tst {
|
||||
, GfmlDocLxrs.Whitespace_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Space() {
|
||||
@Test public void Space() {
|
||||
fx.tst_Doc("a b;", fx.nde_().Atru_("a").Atru_("b"));
|
||||
fx.tst_Tkn("a b;"
|
||||
, fx.tkn_grp_
|
||||
@@ -34,16 +34,16 @@ public class z102_core_whitespace_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Tab() {
|
||||
@Test public void Tab() {
|
||||
fx.tst_Doc("a\tb;", fx.nde_().Atru_("a").Atru_("b"));
|
||||
}
|
||||
@Test public void NewLine() {
|
||||
@Test public void NewLine() {
|
||||
fx.tst_Doc(String_.Format("a{0}b;", String_.CrLf), fx.nde_().Atru_("a").Atru_("b"));
|
||||
}
|
||||
@Test public void MergeSameWs() {
|
||||
@Test public void MergeSameWs() {
|
||||
fx.tst_Doc("a b;", fx.nde_().Atru_("a").Atru_("b"));
|
||||
}
|
||||
@Test public void MergeDiffWs() {
|
||||
@Test public void MergeDiffWs() {
|
||||
fx.tst_Doc("a\t b;", fx.nde_().Atru_("a").Atru_("b"));
|
||||
fx.tst_Tkn("a\t b;"
|
||||
, fx.tkn_grp_
|
||||
@@ -54,7 +54,7 @@ public class z102_core_whitespace_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void LeadingWs() {
|
||||
@Test public void LeadingWs() {
|
||||
fx.tst_Doc(" a;", fx.nde_().Atru_("a"));
|
||||
fx.tst_Tkn(" a;"
|
||||
, fx.tkn_itm_(" ")
|
||||
@@ -64,7 +64,7 @@ public class z102_core_whitespace_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void TrailingWs() {
|
||||
@Test public void TrailingWs() {
|
||||
fx.tst_Doc("a ;", fx.nde_().Atru_("a"));
|
||||
fx.tst_Tkn("a ;"
|
||||
, fx.tkn_grp_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z103_core_elmKey_tst {
|
||||
@@ -23,7 +23,7 @@ public class z103_core_elmKey_tst {
|
||||
, GfmlDocLxrs.ElmKey_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("a=b;", fx.nde_().Atrk_("a", "b"));
|
||||
fx.tst_Tkn("a=b;"
|
||||
, fx.tkn_grp_
|
||||
@@ -32,7 +32,7 @@ public class z103_core_elmKey_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Ws() {
|
||||
@Test public void Ws() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
fx.tst_Tkn("a = b;"
|
||||
, fx.tkn_grp_
|
||||
@@ -41,10 +41,10 @@ public class z103_core_elmKey_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
// @Test public void Err_NotNamed() {
|
||||
// @Test public void Err_NotNamed() {
|
||||
// fx.tst_Err("=", GfmlOutCmds.DatTkn_notFound_Err_());
|
||||
// }
|
||||
// @Test public void Err_NotValued() {
|
||||
// @Test public void Err_NotValued() {
|
||||
// fx.tst_Err("a=;", GfmlOutCmds.elmKey_notValued_Err());
|
||||
// }
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z111_core_comment0_tst {
|
||||
@@ -24,13 +24,13 @@ public class z111_core_comment0_tst {
|
||||
, GfmlDocLxrs.Comment0_lxr() // bgn=// end=\n
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("//a" + String_.Lf);
|
||||
fx.tst_Tkn("//a" + String_.Lf
|
||||
, fx.tkn_grp_ary_("//", "a", String_.Lf)
|
||||
);
|
||||
}
|
||||
@Test public void Data() {
|
||||
@Test public void Data() {
|
||||
fx.tst_Doc("a;//b" + String_.Lf, fx.nde_().Atru_("a"));
|
||||
fx.tst_Tkn("a;//b" + String_.Lf
|
||||
, fx.tkn_grp_
|
||||
@@ -39,7 +39,7 @@ public class z111_core_comment0_tst {
|
||||
, fx.tkn_grp_ary_("//", "b", String_.Lf)
|
||||
);
|
||||
}
|
||||
// @Test public void DanglingBgn() {
|
||||
// @Test public void DanglingBgn() {
|
||||
// try {
|
||||
// fx.tst_Err("//", GfmlOutCmds.Frame_danglingBgn_Err_());
|
||||
// Tfds.Fail_expdError();
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z112_core_comment1_tst {
|
||||
@@ -23,13 +23,13 @@ public class z112_core_comment1_tst {
|
||||
, GfmlDocLxrs.Comment1_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("/*a*/");
|
||||
fx.tst_Tkn("/*a*/"
|
||||
, fx.tkn_grp_ary_("/*", "a", "*/")
|
||||
);
|
||||
}
|
||||
@Test public void Data() {
|
||||
@Test public void Data() {
|
||||
fx.tst_Doc("a;/*b*/", fx.nde_().Atru_("a"));
|
||||
fx.tst_Tkn("a;/*b*/"
|
||||
, fx.tkn_grp_
|
||||
@@ -38,22 +38,22 @@ public class z112_core_comment1_tst {
|
||||
, fx.tkn_grp_ary_("/*", "b", "*/")
|
||||
);
|
||||
}
|
||||
@Test public void IgnoreWs() {
|
||||
@Test public void IgnoreWs() {
|
||||
fx.tst_Tkn("/* b c */"
|
||||
, fx.tkn_grp_ary_("/*", " b c ", "*/")
|
||||
);
|
||||
}
|
||||
@Test public void EscapeBgn() {
|
||||
@Test public void EscapeBgn() {
|
||||
fx.tst_Tkn("/* /*/* */"
|
||||
, fx.tkn_grp_ary_("/*", " ", "/*/*", " ", "*/")
|
||||
);
|
||||
}
|
||||
@Test public void EscapeEnd() {
|
||||
@Test public void EscapeEnd() {
|
||||
fx.tst_Tkn("/* */*/ */"
|
||||
, fx.tkn_grp_ary_("/*", " ", "*/*/", " ", "*/")
|
||||
);
|
||||
}
|
||||
@Test public void Nest() {
|
||||
@Test public void Nest() {
|
||||
fx.tst_Tkn("/* b0 /* c */ b1 */"
|
||||
, fx.tkn_grp_
|
||||
( fx.tkn_itm_("/*")
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z120_quotes_eval0_tst {
|
||||
@@ -23,7 +23,7 @@ public class z120_quotes_eval0_tst {
|
||||
, GfmlDocLxrs.Eval0_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("<~t>;", fx.nde_().Atru_("\t"));
|
||||
fx.tst_Tkn("<~t>;"
|
||||
, fx.tkn_grp_
|
||||
@@ -33,7 +33,7 @@ public class z120_quotes_eval0_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void DoublingIsNotEscaping() {
|
||||
@Test public void DoublingIsNotEscaping() {
|
||||
fx.tst_Doc("<~t>>>;", fx.nde_().Atru_("\t").Atru_(">>")); // >> does not resolve to >
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z121_quotes_quotes0_tst {
|
||||
@@ -23,7 +23,7 @@ public class z121_quotes_quotes0_tst {
|
||||
, GfmlDocLxrs.Quote0_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("'abc';", fx.nde_().Atru_("abc"));
|
||||
fx.tst_Tkn("'abc';"
|
||||
, fx.tkn_grp_
|
||||
@@ -33,7 +33,7 @@ public class z121_quotes_quotes0_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Escape() {
|
||||
@Test public void Escape() {
|
||||
fx.tst_Doc("'a''b';", fx.nde_().Atru_("a'b"));
|
||||
fx.tst_Tkn("'a''b';"
|
||||
, fx.tkn_grp_
|
||||
@@ -43,7 +43,7 @@ public class z121_quotes_quotes0_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void ManyAtrs_LastQuoted() { // bugfix
|
||||
@Test public void ManyAtrs_LastQuoted() { // bugfix
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
fx.tst_Doc("a 'b';", fx.nde_().Atru_("a").Atru_("b"));
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z122_quotes_quote0_eval0_tst {
|
||||
@@ -23,7 +23,7 @@ public class z122_quotes_quote0_eval0_tst {
|
||||
, GfmlDocLxrs.Quote0_Eval0_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("'a<~t>b';", fx.nde_().Atru_("a\tb"));
|
||||
fx.tst_Tkn("'a<~t>b';"
|
||||
, fx.tkn_grp_
|
||||
@@ -39,7 +39,7 @@ public class z122_quotes_quote0_eval0_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void QuoteInside() {
|
||||
@Test public void QuoteInside() {
|
||||
fx.tst_Doc("'a<~'t'>b';", fx.nde_().Atru_("a\tb"));
|
||||
fx.tst_Tkn("'a<~'t'>b';"
|
||||
, fx.tkn_grp_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z123_quotes_quoteBlock_tst {
|
||||
@@ -23,16 +23,16 @@ public class z123_quotes_quoteBlock_tst {
|
||||
, GfmlDocLxrs.QuoteBlock_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("|'abc'|;", fx.nde_().Atru_("abc"));
|
||||
}
|
||||
@Test public void Escape_bgn() {
|
||||
@Test public void Escape_bgn() {
|
||||
fx.tst_Doc("|'a|'|'b'|;", fx.nde_().Atru_("a|'b"));
|
||||
}
|
||||
@Test public void Escape_end() {
|
||||
@Test public void Escape_end() {
|
||||
fx.tst_Doc("|'a'|'|b'|;", fx.nde_().Atru_("a'|b"));
|
||||
}
|
||||
@Test public void Nest() {
|
||||
@Test public void Nest() {
|
||||
fx.tst_Doc("|'a|'-'|b'|;", fx.nde_().Atru_("a-b"));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z124_quotes_quoteFold_tst {
|
||||
@@ -23,10 +23,10 @@ public class z124_quotes_quoteFold_tst {
|
||||
, GfmlDocLxrs.QuoteFold_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Quote() {
|
||||
@Test public void Quote() {
|
||||
fx.tst_Doc("^'a b'^;", fx.nde_().Atru_("a b"));
|
||||
}
|
||||
@Test public void Tab() {
|
||||
@Test public void Tab() {
|
||||
fx.tst_Doc("^'a\tb'^;", fx.nde_().Atru_("ab"));
|
||||
fx.tst_Tkn("^'a\tb'^;"
|
||||
, fx.tkn_grp_
|
||||
@@ -35,25 +35,25 @@ public class z124_quotes_quoteFold_tst {
|
||||
, fx.tkn_itm_(";"))
|
||||
);
|
||||
}
|
||||
@Test public void NewLine() {
|
||||
@Test public void NewLine() {
|
||||
fx.tst_Doc(String_.Concat("^'a", String_.CrLf, "b'^;"), fx.nde_().Atru_("ab"));
|
||||
}
|
||||
@Test public void Eval() {
|
||||
@Test public void Eval() {
|
||||
fx.tst_Doc("^'a<~t>b'^;", fx.nde_().Atru_("a\tb"));
|
||||
}
|
||||
@Test public void Nest() {
|
||||
@Test public void Nest() {
|
||||
fx.tst_Doc("^'a^'-'^b'^;", fx.nde_().Atru_("a-b"));
|
||||
}
|
||||
@Test public void EscapeBgn() {
|
||||
@Test public void EscapeBgn() {
|
||||
fx.tst_Doc("^'a^'^'b'^;", fx.nde_().Atru_("a^'b"));
|
||||
}
|
||||
@Test public void EscapeEnd() {
|
||||
@Test public void EscapeEnd() {
|
||||
fx.tst_Doc("^'a'^'^b'^;", fx.nde_().Atru_("a'^b"));
|
||||
}
|
||||
@Test public void Comment0() {
|
||||
@Test public void Comment0() {
|
||||
fx.tst_Doc(String_.Concat("^'a//comment", String_.CrLf, "b'^;"), fx.nde_().Atru_("ab"));
|
||||
}
|
||||
@Test public void Comment1() {
|
||||
@Test public void Comment1() {
|
||||
fx.tst_Doc("^'a/*comment*/b'^;", fx.nde_().Atru_("ab"));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z151_ndeSubs_basic_tst {
|
||||
@@ -23,29 +23,29 @@ public class z151_ndeSubs_basic_tst {
|
||||
, GfmlDocLxrs.NdeBodyEnd_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("{}", fx.nde_());
|
||||
fx.tst_Tkn("{}"
|
||||
, fx.tkn_grp_ary_("{", "}")
|
||||
);
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Doc("{}{}", fx.nde_(), fx.nde_());
|
||||
}
|
||||
@Test public void Nested() {
|
||||
@Test public void Nested() {
|
||||
fx.tst_Doc("{{}}"
|
||||
, fx.nde_().Subs_
|
||||
( fx.nde_())
|
||||
);
|
||||
}
|
||||
@Test public void NestedMany() {
|
||||
@Test public void NestedMany() {
|
||||
fx.tst_Doc("{{}{}}"
|
||||
, fx.nde_().Subs_
|
||||
( fx.nde_()
|
||||
, fx.nde_()
|
||||
));
|
||||
}
|
||||
@Test public void Complex() {
|
||||
@Test public void Complex() {
|
||||
fx.tst_Doc(String_.Concat
|
||||
( "{"
|
||||
, "{"
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z152_ndeSubs_data_tst {
|
||||
@@ -25,37 +25,37 @@ public class z152_ndeSubs_data_tst {
|
||||
, GfmlDocLxrs.Whitespace_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void ToInline() {
|
||||
@Test public void ToInline() {
|
||||
fx.tst_Doc("{a;}"
|
||||
, fx.nde_().Subs_
|
||||
( fx.nde_().Atru_("a"))
|
||||
);
|
||||
}
|
||||
@Test public void ToInline_many() {
|
||||
@Test public void ToInline_many() {
|
||||
fx.tst_Doc("{a b;}"
|
||||
, fx.nde_().Subs_
|
||||
( fx.nde_().Atru_("a").Atru_("b"))
|
||||
);
|
||||
}
|
||||
@Test public void ToBody() {
|
||||
@Test public void ToBody() {
|
||||
fx.tst_Doc("{a{}}"
|
||||
, fx.nde_().Subs_
|
||||
( fx.nde_().Atru_("a"))
|
||||
);
|
||||
}
|
||||
@Test public void ToBody_many() {
|
||||
@Test public void ToBody_many() {
|
||||
fx.tst_Doc("{a b{}}"
|
||||
, fx.nde_().Subs_
|
||||
( fx.nde_().Atru_("a").Atru_("b"))
|
||||
);
|
||||
}
|
||||
@Test public void ToBody_manyNest() {
|
||||
@Test public void ToBody_manyNest() {
|
||||
fx.tst_Doc("a{b;}"
|
||||
, fx.nde_().Atru_("a").Subs_
|
||||
( fx.nde_().Atru_("b"))
|
||||
);
|
||||
}
|
||||
@Test public void ToBody_many2() {
|
||||
@Test public void ToBody_many2() {
|
||||
fx.tst_Doc("a{b{c;}}"
|
||||
, fx.nde_().Atru_("a").Subs_
|
||||
( fx.nde_().Atru_("b").Subs_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z161_ndeHdrs_inline_tst {
|
||||
@@ -24,19 +24,19 @@ public class z161_ndeHdrs_inline_tst {
|
||||
, GfmlDocLxrs.Whitespace_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("a:;", fx.nde_().Hnd_("a"));
|
||||
fx.tst_Tkn("a:;"
|
||||
, fx.tkn_grp_ary_("a", ":", ";")
|
||||
);
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Doc("a:;b:;"
|
||||
, fx.nde_().Hnd_("a")
|
||||
, fx.nde_().Hnd_("b")
|
||||
);
|
||||
}
|
||||
@Test public void Ws() {
|
||||
@Test public void Ws() {
|
||||
fx.tst_Tkn("a : ;"
|
||||
, fx.tkn_grp_ary_("a", " ", ":", " ", ";")
|
||||
);
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z162_ndeHdrs_err_tst {
|
||||
@@ -22,10 +22,10 @@ public class z162_ndeHdrs_err_tst {
|
||||
( GfmlDocLxrs.NdeHeader_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void NotNamed() {
|
||||
@Test public void NotNamed() {
|
||||
fx.tst_Err(":", UsrMsg_mok.new_(GfmlUsrMsgs.fail_DatTkn_notFound()));
|
||||
}
|
||||
@Test public void Dangling() {
|
||||
@Test public void Dangling() {
|
||||
fx.tst_Err("a{", UsrMsg_mok.new_(GfmlUsrMsgs.fail_Frame_danglingBgn()));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z163_ndeHdrs_body_tst {
|
||||
@@ -24,22 +24,22 @@ public class z163_ndeHdrs_body_tst {
|
||||
, GfmlDocLxrs.NdeBodyEnd_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("a:{}", fx.nde_().Hnd_("a"));
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Doc("a:{}b:{}"
|
||||
, fx.nde_().Hnd_("a")
|
||||
, fx.nde_().Hnd_("b")
|
||||
);
|
||||
}
|
||||
@Test public void Nested() {
|
||||
@Test public void Nested() {
|
||||
fx.tst_Doc("a:{b:{}}"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().Hnd_("b"))
|
||||
);
|
||||
}
|
||||
@Test public void NestedMany() {
|
||||
@Test public void NestedMany() {
|
||||
fx.tst_Doc("a:{b:{}c:{}}"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().Hnd_("b")
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z164_hdeHdrs_data_tst {
|
||||
@@ -26,7 +26,7 @@ public class z164_hdeHdrs_data_tst {
|
||||
, GfmlDocLxrs.NdeBodyEnd_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Bas1() {
|
||||
@Test public void Bas1() {
|
||||
fx.tst_Tkn("a:b;"
|
||||
, fx.tkn_grp_
|
||||
( fx.tkn_itm_("a")
|
||||
@@ -35,7 +35,7 @@ public class z164_hdeHdrs_data_tst {
|
||||
, fx.tkn_itm_(";")
|
||||
));
|
||||
}
|
||||
@Test public void Basic3() {
|
||||
@Test public void Basic3() {
|
||||
fx.tst_Tkn("a:b{c;}"
|
||||
, fx.tkn_grp_
|
||||
( fx.tkn_itm_("a")
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z181_ndeDots_basic_tst {
|
||||
@@ -25,7 +25,7 @@ public class z181_ndeDots_basic_tst {
|
||||
, GfmlDocLxrs.NdeBodyEnd_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void One() {
|
||||
@Test public void One() {
|
||||
fx.tst_Doc("{a.b;c;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
@@ -49,7 +49,7 @@ public class z181_ndeDots_basic_tst {
|
||||
, fx.tkn_itm_("}")
|
||||
));
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Doc("{a.b.c.d;e;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z182_ndeDots_subs_tst {
|
||||
@@ -24,7 +24,7 @@ public class z182_ndeDots_subs_tst {
|
||||
, GfmlDocLxrs.NdeBodyEnd_lxr()
|
||||
);
|
||||
} GfmlParse_fxt fx = GfmlParse_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("{a.b{}z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
@@ -33,7 +33,7 @@ public class z182_ndeDots_subs_tst {
|
||||
, fx.nde_().Atru_("z").ChainId_(0)
|
||||
));
|
||||
}
|
||||
@Test public void Nest() {
|
||||
@Test public void Nest() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.NdeHeader_lxr());
|
||||
fx.tst_Doc("{a.b.c{d:e;}z;}" // shorthand of {a{b{c{d:e;}}}}
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
@@ -47,7 +47,7 @@ public class z182_ndeDots_subs_tst {
|
||||
, fx.nde_().ChainId_(0).Atru_("z")
|
||||
));
|
||||
}
|
||||
@Test public void Chain() {
|
||||
@Test public void Chain() {
|
||||
fx.tst_Doc("{a.b.c;z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
@@ -57,7 +57,7 @@ public class z182_ndeDots_subs_tst {
|
||||
, fx.nde_().ChainId_(0).Atru_("z")
|
||||
));
|
||||
}
|
||||
@Test public void NdeHdr() {
|
||||
@Test public void NdeHdr() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.NdeHeader_lxr());
|
||||
fx.tst_Doc("{a:b.c;z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z183_ndeDots_parens_tst {
|
||||
@@ -26,7 +26,7 @@ public class z183_ndeDots_parens_tst {
|
||||
, GfmlDocLxrs.NdeHdrEnd_lxr()
|
||||
);
|
||||
} GfmlParse_fxt fx = GfmlParse_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("{a.b(c);z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
@@ -35,7 +35,7 @@ public class z183_ndeDots_parens_tst {
|
||||
, fx.nde_().ChainId_(0).Atru_("z")
|
||||
));
|
||||
}
|
||||
@Test public void Basic_tkn() {
|
||||
@Test public void Basic_tkn() {
|
||||
//A_('1');
|
||||
fx.tst_Tkn("a(c);"
|
||||
, fx.tkn_grp_
|
||||
@@ -45,7 +45,7 @@ public class z183_ndeDots_parens_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Basic2_tkn() {
|
||||
@Test public void Basic2_tkn() {
|
||||
fx.tst_Tkn("a.b(c);"
|
||||
, fx.tkn_grp_
|
||||
( fx.tkn_itm_("a"), fx.tkn_itm_(".")
|
||||
@@ -55,7 +55,7 @@ public class z183_ndeDots_parens_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
fx.tst_Doc("{a.b(c d e);z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
@@ -65,7 +65,7 @@ public class z183_ndeDots_parens_tst {
|
||||
, fx.nde_().ChainId_(0).Atru_("z")
|
||||
));
|
||||
}
|
||||
// @Test public void Many2() {
|
||||
// @Test public void Many2() {
|
||||
// fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
// fx.tst_Doc("{a.b(c){d();}}"
|
||||
// , fx.nde_().ChainId_(0).Subs_
|
||||
@@ -76,7 +76,7 @@ public class z183_ndeDots_parens_tst {
|
||||
// )
|
||||
// ));
|
||||
// }
|
||||
@Test public void Chain() {
|
||||
@Test public void Chain() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
fx.tst_Doc("{a.b(c).d(e);z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
@@ -88,7 +88,7 @@ public class z183_ndeDots_parens_tst {
|
||||
, fx.nde_().ChainId_(0).Atru_("z")
|
||||
));
|
||||
}
|
||||
@Test public void Nest() {
|
||||
@Test public void Nest() {
|
||||
fx.tst_Doc("{a.b(c.d);z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
@@ -101,7 +101,7 @@ public class z183_ndeDots_parens_tst {
|
||||
, fx.nde_().Atru_("z")
|
||||
));
|
||||
}
|
||||
@Test public void Nest_longer() {
|
||||
@Test public void Nest_longer() {
|
||||
fx.tst_Doc("{a.b.c(d.e.f);z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
@@ -118,7 +118,7 @@ public class z183_ndeDots_parens_tst {
|
||||
, fx.nde_().Atru_("z")
|
||||
));
|
||||
}
|
||||
@Test public void Nest_deeper() {
|
||||
@Test public void Nest_deeper() {
|
||||
fx.tst_Doc("{a.b(c.d(e.f));z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
( fx.nde_().Hnd_("a").ChainId_(1).Subs_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z184_ndeDots_atrSpr_tst {
|
||||
@@ -27,7 +27,7 @@ public class z184_ndeDots_atrSpr_tst {
|
||||
, GfmlDocLxrs.AtrSpr_lxr()
|
||||
);
|
||||
} GfmlParse_fxt fx = GfmlParse_fxt.new_();
|
||||
@Test public void NestMult() {
|
||||
@Test public void NestMult() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.AtrSpr_lxr());
|
||||
fx.tst_Doc("{a.b(c.d,e.f);z;}"
|
||||
, fx.nde_().ChainId_(0).Subs_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z191_ndeProps_basic_tst {
|
||||
@@ -27,20 +27,20 @@ public class z191_ndeProps_basic_tst {
|
||||
, GfmlDocLxrs.NdeInline_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Doc("a:[b]{}"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Atru_("b"))
|
||||
);
|
||||
}
|
||||
@Test public void Basic_empty() {
|
||||
@Test public void Basic_empty() {
|
||||
fx.tst_Tkn("[];"
|
||||
, fx.tkn_grp_
|
||||
( fx.tkn_grp_ary_("[", "]")
|
||||
, fx.tkn_itm_(";")
|
||||
));
|
||||
}
|
||||
@Test public void Hdr() {
|
||||
@Test public void Hdr() {
|
||||
fx.tst_Tkn("a[];"
|
||||
, fx.tkn_grp_
|
||||
( fx.tkn_grp_ary_("a")
|
||||
@@ -48,52 +48,52 @@ public class z191_ndeProps_basic_tst {
|
||||
, fx.tkn_itm_(";")
|
||||
));
|
||||
}
|
||||
@Test public void WithInnerNde() {
|
||||
@Test public void WithInnerNde() {
|
||||
fx.tst_Doc("a:[b]{c;}"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Atru_("b")
|
||||
, fx.nde_().Atru_("c")
|
||||
));
|
||||
}
|
||||
@Test public void DoesNotUsurpDatTknForName() {
|
||||
@Test public void DoesNotUsurpDatTknForName() {
|
||||
fx.tst_Doc("a:b[c]{}"
|
||||
, fx.nde_().Hnd_("a").Atru_("b").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Atru_("c")
|
||||
));
|
||||
}
|
||||
@Test public void NoHeader_body() {
|
||||
@Test public void NoHeader_body() {
|
||||
fx.tst_Doc("a[b]{}"
|
||||
, fx.nde_().Atru_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Atru_("b")
|
||||
));
|
||||
}
|
||||
@Test public void NoHeader_inline() {
|
||||
@Test public void NoHeader_inline() {
|
||||
fx.tst_Doc("a[b];"
|
||||
, fx.nde_().Atru_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Atru_("b")
|
||||
));
|
||||
}
|
||||
@Test public void Nesting() {
|
||||
@Test public void Nesting() {
|
||||
fx.tst_Doc("a:[b:;]{}"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Subs_
|
||||
( fx.nde_().Hnd_("b"))
|
||||
));
|
||||
}
|
||||
@Test public void Nesting2() {
|
||||
@Test public void Nesting2() {
|
||||
fx.tst_Doc("a:[b{}]{}"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Atru_("b")
|
||||
));
|
||||
}
|
||||
@Test public void CanBeKeyed_header() {
|
||||
@Test public void CanBeKeyed_header() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.ElmKey_lxr());
|
||||
fx.tst_Doc("a:b=[c];"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().KeyedSubObj_().Key_("b").Atru_("c")
|
||||
));
|
||||
}
|
||||
@Test public void CanBeKeyed2_inline() {
|
||||
@Test public void CanBeKeyed2_inline() {
|
||||
fx.ini_RootLxr_Add
|
||||
( GfmlDocLxrs.Whitespace_lxr()
|
||||
, GfmlDocLxrs.ElmKey_lxr()
|
||||
@@ -103,12 +103,12 @@ public class z191_ndeProps_basic_tst {
|
||||
( fx.nde_().KeyedSubObj_().Key_("b").Atru_("c")
|
||||
));
|
||||
}
|
||||
@Test public void Sole() {
|
||||
@Test public void Sole() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
fx.tst_Doc("[a b]"
|
||||
, fx.nde_().KeyedSubObj_().Atru_("a").Atru_("b"));
|
||||
}
|
||||
@Test public void Nest1() {
|
||||
@Test public void Nest1() {
|
||||
fx.ini_RootLxr_Add(GfmlDocLxrs.Whitespace_lxr());
|
||||
fx.tst_Doc("[a [b]]"
|
||||
, fx.nde_().Atru_("a").Subs_
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z192_ndeProps_dots_tst {
|
||||
@@ -27,7 +27,7 @@ public class z192_ndeProps_dots_tst {
|
||||
, GfmlDocLxrs.NdePropEnd_lxr()
|
||||
);
|
||||
}
|
||||
@Test public void Stress() {
|
||||
@Test public void Stress() {
|
||||
fx.tst_Doc("a.b[c];"
|
||||
, fx.nde_().Hnd_("a").Subs_
|
||||
( fx.nde_().Hnd_("b").Subs_
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z400_GfmlTypeMakr_tst {
|
||||
@Before public void setup() {
|
||||
makr = GfmlTypeMakr.new_();
|
||||
} GfmlTypeMakr makr; GfmlType type; GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void MakeSubType() {
|
||||
@Test public void MakeSubType() {
|
||||
type = makr.MakeSubType("point", "x", "y");
|
||||
fx.tst_Type
|
||||
( fx.typ_().Key_("point").Subs_
|
||||
@@ -30,7 +30,7 @@ public class z400_GfmlTypeMakr_tst {
|
||||
);
|
||||
tst_XtoAry(makr, "point");
|
||||
}
|
||||
@Test public void MakeSubTypeAsOwner() {
|
||||
@Test public void MakeSubTypeAsOwner() {
|
||||
type = makr.MakeSubTypeAsOwner("item");
|
||||
fx.tst_Type
|
||||
( fx.typ_().Key_("item")
|
||||
@@ -39,7 +39,7 @@ public class z400_GfmlTypeMakr_tst {
|
||||
tst_Owner(makr, "item");
|
||||
tst_XtoAry(makr, "item");
|
||||
}
|
||||
@Test public void MakeSubTypeAsOwner_MakeSubType() {
|
||||
@Test public void MakeSubTypeAsOwner_MakeSubType() {
|
||||
type = makr.MakeSubTypeAsOwner("item");
|
||||
makr.MakeSubType("pos", "x", "y");
|
||||
fx.tst_Type
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z401_types_compile_basic_tst {
|
||||
@Before public void setup() {
|
||||
fx.run_InitPragma(fx.Regy(), GfmlPragmaType.new_());
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("point", "gfml.point").Subs_
|
||||
( fx.nde_().Atru_("x")
|
||||
@@ -28,7 +28,7 @@ public class z401_types_compile_basic_tst {
|
||||
, fx.typ_().Name_("point").Key_("gfml.point").Atrs_("x", "y")
|
||||
);
|
||||
}
|
||||
@Test public void Nest() {
|
||||
@Test public void Nest() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("item", "gfml.item").Subs_
|
||||
( fx.nde_().Atru_("pos").Atrk_("type", "gfml.item.point")
|
||||
@@ -38,7 +38,7 @@ public class z401_types_compile_basic_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void NestMany() {
|
||||
@Test public void NestMany() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("item", "gfml.item").Subs_
|
||||
( fx.nde_().Atru_("pos").Atrk_("type", "gfml.item.point")
|
||||
@@ -50,7 +50,7 @@ public class z401_types_compile_basic_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Recurse() {
|
||||
@Test public void Recurse() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("widget", "gfml.widget").Subs_
|
||||
( fx.nde_().Atru_("widget").Atrk_("type", "gfml.widget")
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z402_types_compile_implicit_tst {
|
||||
@Before public void setup() {
|
||||
fx.run_InitPragma(fx.Regy(), GfmlPragmaType.new_());
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Fld_typeKey_leaf() {
|
||||
@Test public void Fld_typeKey_leaf() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("point", "gfml.point").Subs_
|
||||
( fx.nde_().Atru_("x").Atrk_("type", "gfml.int") // explicit
|
||||
@@ -30,7 +30,7 @@ public class z402_types_compile_implicit_tst {
|
||||
, fx.fld_().Name_("y").TypeKey_("gfml.String")
|
||||
));
|
||||
}
|
||||
@Test public void Fld_typeKey_nest() {
|
||||
@Test public void Fld_typeKey_nest() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("rect", "gfml.rect").Subs_
|
||||
( fx.nde_().Atru_("pos").Atrk_("type", "gfml.point").Subs_ // explicit
|
||||
@@ -47,7 +47,7 @@ public class z402_types_compile_implicit_tst {
|
||||
, fx.fld_().Name_("size").TypeKey_("gfml.rect/size")
|
||||
));
|
||||
}
|
||||
@Test public void Typ_key() {
|
||||
@Test public void Typ_key() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("point", "gfml.point") // explicit: gfml.point
|
||||
, fx.typ_().Name_("point").Key_("gfml.point")
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z403_types_compile_default_tst {
|
||||
@Before public void setup() {
|
||||
fx.run_InitPragma(fx.Regy(), GfmlPragmaType.new_());
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("point", "gfml.point").Subs_
|
||||
( fx.nde_().Atru_("x").Atrk_("default", "10")
|
||||
@@ -30,7 +30,7 @@ public class z403_types_compile_default_tst {
|
||||
, fx.fld_().Name_("y").Default_(GfmlTkn_.NullRaw)
|
||||
));
|
||||
}
|
||||
@Test public void Nde() {
|
||||
@Test public void Nde() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("rect", "gfml.rect").Subs_
|
||||
( fx.nde_().Atru_("point").Subs_
|
||||
@@ -41,7 +41,7 @@ public class z403_types_compile_default_tst {
|
||||
( ndek_("point", atr_("x", "1"), atr_("y", "2")))
|
||||
));
|
||||
}
|
||||
@Test public void Nde_unnamed() {
|
||||
@Test public void Nde_unnamed() {
|
||||
fx.tst_Compile
|
||||
( fx.nde_().Atrs_("rect", "gfml.rect").Subs_
|
||||
( fx.nde_().Atru_("point").Subs_
|
||||
|
||||
@@ -1,60 +1,60 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z411_types_apply_atrs_basic_tst {
|
||||
@Before public void setup() {
|
||||
pointType = fx.typ_().Key_("point").Atrs_("x", "y", "z");
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_(); GfmlTyp_mok pointType;
|
||||
@Test public void Unnamed_one() {
|
||||
@Test public void Unnamed_one() {
|
||||
fx.tst_Resolve
|
||||
( pointType
|
||||
, fx.nde_().Hnd_("point").Atru_("10")
|
||||
, fx.nde_().Typ_("point").Atrk_("x", "10")
|
||||
);
|
||||
}
|
||||
@Test public void Unnamed_three() {
|
||||
@Test public void Unnamed_three() {
|
||||
fx.tst_Resolve
|
||||
( pointType
|
||||
, fx.nde_().Hnd_("point").Atrs_("10", "20", "30")
|
||||
, fx.nde_().Typ_("point").Atrk_("x", "10").Atrk_("y", "20").Atrk_("z", "30")
|
||||
);
|
||||
}
|
||||
@Test public void Keys_partial1() {
|
||||
@Test public void Keys_partial1() {
|
||||
fx.tst_Resolve
|
||||
( pointType
|
||||
, fx.nde_().Hnd_("point").Atrk_("x", "10").Atrs_("20", "30")
|
||||
, fx.nde_().Typ_("point").Atrk_("x", "10").Atrk_("y", "20").Atrk_("z", "30")
|
||||
);
|
||||
}
|
||||
@Test public void Keys_partial2() {
|
||||
@Test public void Keys_partial2() {
|
||||
fx.tst_Resolve
|
||||
( pointType
|
||||
, fx.nde_().Hnd_("point").Atrk_("x", "10").Atrk_("y", "20").Atru_("30")
|
||||
, fx.nde_().Typ_("point").Atrk_("x", "10").Atrk_("y", "20").Atrk_("z", "30")
|
||||
);
|
||||
}
|
||||
@Test public void OutOfOrder_z_1() {
|
||||
@Test public void OutOfOrder_z_1() {
|
||||
fx.tst_Resolve
|
||||
( pointType
|
||||
, fx.nde_().Hnd_("point").Atrk_("z", "30").Atrs_("10", "20")
|
||||
, fx.nde_().Typ_("point").Atrk_("z", "30").Atrk_("x", "10").Atrk_("y", "20")
|
||||
);
|
||||
}
|
||||
@Test public void OutOfOrder_z_2() {
|
||||
@Test public void OutOfOrder_z_2() {
|
||||
fx.tst_Resolve
|
||||
( pointType
|
||||
, fx.nde_().Hnd_("point").Atru_("10").Atrk_("z", "30").Atru_("20")
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z421_types_apply_ndes_basic_tst {
|
||||
@@ -27,7 +27,7 @@ public class z421_types_apply_ndes_basic_tst {
|
||||
( GfmlFld_mok.new_().ini_ndk_("pos", "pos")
|
||||
).XtoGfmlType());
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void NamedNde_but_UnnamedAtr() {
|
||||
@Test public void NamedNde_but_UnnamedAtr() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("rect").Subs_
|
||||
( fx.nde_().Key_("pos").Atrs_("1")
|
||||
@@ -37,7 +37,7 @@ public class z421_types_apply_ndes_basic_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void UnnamedNde() {
|
||||
@Test public void UnnamedNde() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("rect").Subs_
|
||||
( fx.nde_().Key_(GfmlTkn_.NullRaw).Atrs_("1")
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z422_types_apply_ndes_multi_tst {
|
||||
@@ -33,7 +33,7 @@ public class z422_types_apply_ndes_multi_tst {
|
||||
, GfmlFld_mok.new_().ini_ndk_("size", "size")
|
||||
).XtoGfmlType());
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Unnamed() {
|
||||
@Test public void Unnamed() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("rect").Subs_
|
||||
( fx.nde_().Key_(GfmlTkn_.NullRaw).Atrs_("1")
|
||||
@@ -45,7 +45,7 @@ public class z422_types_apply_ndes_multi_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Partial() {
|
||||
@Test public void Partial() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("rect").Subs_
|
||||
( fx.nde_().Key_("pos").Atrs_("1")
|
||||
@@ -57,7 +57,7 @@ public class z422_types_apply_ndes_multi_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void OutOfOrder() {
|
||||
@Test public void OutOfOrder() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("rect").Subs_
|
||||
( fx.nde_().Key_("size").Atrs_("3")
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z423_types_apply_ndes_misc_tst {
|
||||
@Before public void setup() {
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Recurse() {
|
||||
@Test public void Recurse() {
|
||||
fx.Regy().Add(
|
||||
fx.typ_().Key_("item").Subs_
|
||||
( GfmlFld_mok.new_().ini_atr_("key")
|
||||
@@ -31,7 +31,7 @@ public class z423_types_apply_ndes_misc_tst {
|
||||
( fx.nde_().Hnd_("item").Atrk_("key", "2")
|
||||
));
|
||||
}
|
||||
@Test public void OwnerTypePrecedesTopLevel() {
|
||||
@Test public void OwnerTypePrecedesTopLevel() {
|
||||
GfmlTypeMakr makr = GfmlTypeMakr.new_();
|
||||
GfmlType topLevelSize = makr.MakeSubType("size", "width", "height");
|
||||
GfmlType rect = makr.MakeSubTypeAsOwner("rect");
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z424_types_apply_ndes_nest_tst {
|
||||
@@ -22,7 +22,7 @@ public class z424_types_apply_ndes_nest_tst {
|
||||
makr.MakeSubType("pos", "x", "y");
|
||||
fx.Regy().Add_ary(makr.Xto_bry());
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void InvokeByHnd() {
|
||||
@Test public void InvokeByHnd() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("gfml.item").Subs_
|
||||
( fx.nde_().Hnd_("pos").Atrs_("10", "20"))
|
||||
@@ -30,7 +30,7 @@ public class z424_types_apply_ndes_nest_tst {
|
||||
( fx.nde_().Typ_("gfml.item/pos").Atrk_("x", "10").Atrk_("y", "20")
|
||||
));
|
||||
}
|
||||
@Test public void InvokeByTyp() {
|
||||
@Test public void InvokeByTyp() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("gfml.item").Subs_
|
||||
( fx.nde_().Hnd_("gfml.item/pos").Atrs_("10", "20"))
|
||||
@@ -38,7 +38,7 @@ public class z424_types_apply_ndes_nest_tst {
|
||||
( fx.nde_().Typ_("gfml.item/pos").Atrk_("x", "10").Atrk_("y", "20")
|
||||
));
|
||||
}
|
||||
@Test public void NoInvokeByName() {
|
||||
@Test public void NoInvokeByName() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("gfml.item").Subs_
|
||||
( fx.nde_().Hnd_("gfml.item").Atrs_("10", "20")) // item is not in .SubFlds, but is in regy
|
||||
@@ -46,7 +46,7 @@ public class z424_types_apply_ndes_nest_tst {
|
||||
( fx.nde_().Typ_("gfml.item").Atrs_("10", "20")
|
||||
));
|
||||
}
|
||||
@Test public void Name_subLevel() {
|
||||
@Test public void Name_subLevel() {
|
||||
GfmlTypeMakr makr = GfmlTypeMakr.new_();
|
||||
makr.MakeRootType("font", "size");
|
||||
makr.MakeSubType("color", "name");
|
||||
@@ -56,7 +56,7 @@ public class z424_types_apply_ndes_nest_tst {
|
||||
, fx.nde_().Typ_(GfmlType_.AnyKey).Atru_("blue")// confirm that subFlds in other types are not selectable by name; i.e.: must be font/color, not just color
|
||||
);
|
||||
}
|
||||
@Test public void Unresolved() {
|
||||
@Test public void Unresolved() {
|
||||
fx.tst_Resolve
|
||||
( fx.nde_().Hnd_("").Atrs_("10", "20")
|
||||
, fx.nde_().Typ_(GfmlType_.AnyKey).Atrs_("10", "20")
|
||||
|
||||
@@ -1,30 +1,30 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z441_types_parse_basic_tst {
|
||||
GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Null() {
|
||||
@Test public void Null() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "point:1;"
|
||||
)
|
||||
, fx.nde_().Hnd_("point").Typ_(GfmlType_.AnyKey).Atru_("1")
|
||||
);
|
||||
}
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "point {"
|
||||
@@ -36,7 +36,7 @@ public class z441_types_parse_basic_tst {
|
||||
, fx.nde_().Hnd_("point").Typ_("point").Atrk_("x", "1")
|
||||
);
|
||||
}
|
||||
@Test public void MultipleAtrs() {
|
||||
@Test public void MultipleAtrs() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "point {"
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z442_types_parse_default_tst {
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "point {x;}"
|
||||
@@ -26,7 +26,7 @@ public class z442_types_parse_default_tst {
|
||||
, fx.nde_().Hnd_("point").Typ_("point").Atrk_("x", "1")
|
||||
);
|
||||
}
|
||||
@Test public void Pinned() {
|
||||
@Test public void Pinned() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "point {x;}"
|
||||
@@ -38,7 +38,7 @@ public class z442_types_parse_default_tst {
|
||||
, fx.nde_().Hnd_("point").Typ_("point").Atrk_("x", "2")
|
||||
);
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "point {x;}" // point is always pinned
|
||||
@@ -51,7 +51,7 @@ public class z442_types_parse_default_tst {
|
||||
, fx.nde_().Hnd_("point").Typ_("point").Atrk_("x", "2")
|
||||
);
|
||||
}
|
||||
@Test public void Nested() {
|
||||
@Test public void Nested() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "item {"
|
||||
@@ -65,7 +65,7 @@ public class z442_types_parse_default_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void NestedWithAtr() {
|
||||
@Test public void NestedWithAtr() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "item {"
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z443_types_parse_keyd_tst {
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "[10 12];"
|
||||
)
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z451_dflts_compile_tst {
|
||||
@@ -21,14 +21,14 @@ public class z451_dflts_compile_tst {
|
||||
pragma = GfmlPragmaDefault.new_();
|
||||
fx_typ.run_InitPragma(regy, pragma);
|
||||
} GfmlTypRegy regy; GfmlPragmaDefault pragma; GfmlDefaultItem_fxt fx = GfmlDefaultItem_fxt.new_(); GfmlTypeCompiler_fxt fx_typ = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
GfmlNde gnde = fx_typ.run_Resolve(regy, "_default/type/atr"
|
||||
, fx_typ.nde_().Atru_("x").Atru_("10")
|
||||
);
|
||||
GfmlDefaultItem actl = pragma.CompileItem(gnde, "point");
|
||||
fx.tst_Item(actl, fx.make_("point", "x", "10"));
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
GfmlNde gnde = fx_typ.run_Resolve(regy, "_default/type"
|
||||
, fx_typ.nde_().Atru_("point").Subs_
|
||||
( fx_typ.nde_().Atrs_("x", "10")
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z452_dflts_exec_tst {
|
||||
@Before public void setup() {
|
||||
type = make_("gfml.point", "point", "x");
|
||||
} GfmlDefaultItem item; GfmlType type; GfmlDefaultItem_fxt fx_item = GfmlDefaultItem_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
tst_SubFldDefault(type, "x", null);
|
||||
|
||||
item = fx_item.make_("gfml.point", "x", "10");
|
||||
@@ -29,7 +29,7 @@ public class z452_dflts_exec_tst {
|
||||
item.Exec_end(type);
|
||||
tst_SubFldDefault(type, "x", null);
|
||||
}
|
||||
@Test public void Overwrite() {
|
||||
@Test public void Overwrite() {
|
||||
ini_SubFldDefault_add(type, "x", "0");
|
||||
tst_SubFldDefault(type, "x", "0");
|
||||
|
||||
@@ -40,7 +40,7 @@ public class z452_dflts_exec_tst {
|
||||
item.Exec_end(type);
|
||||
tst_SubFldDefault(type, "x", "0");
|
||||
}
|
||||
@Test public void CreateDefault() {
|
||||
@Test public void CreateDefault() {
|
||||
tst_SubFldExists(type, "y", false);
|
||||
|
||||
item = fx_item.make_("gfml.point", "y", "10");
|
||||
@@ -51,7 +51,7 @@ public class z452_dflts_exec_tst {
|
||||
item.Exec_end(type);
|
||||
tst_SubFldExists(type, "y", false);
|
||||
}
|
||||
@Test public void DefaultTkn() {
|
||||
@Test public void DefaultTkn() {
|
||||
Object[] ary = ini_eval_("0");
|
||||
GfmlTkn varTkn = (GfmlTkn)ary[0];
|
||||
GfmlVarItm varItem = (GfmlVarItm)ary[1];
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z455_dflts_scope_tst {
|
||||
@@ -23,7 +23,7 @@ public class z455_dflts_scope_tst {
|
||||
GfmlType type = makr.MakeRootType("point", "point", "x", "y").DocPos_(rootPos);
|
||||
regy.Add(type);
|
||||
} GfmlDocPos rootPos, currPos; GfmlTypRegy regy;
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
currPos = rootPos.NewDown(0);
|
||||
tst_FetchOrNullByPos(regy, "point", rootPos, "point", "x", "y");
|
||||
tst_FetchOrNullByPos(regy, "point", currPos, "point", "x", "y");
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z456_dflts_parse_tst {
|
||||
@Test public void Fix_DefaultChangesPinnedType() {
|
||||
@Test public void Fix_DefaultChangesPinnedType() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_type:{"
|
||||
, "item {"
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z481_vars_compile_tst {
|
||||
@@ -21,7 +21,7 @@ public class z481_vars_compile_tst {
|
||||
pragma = GfmlPragmaVar.new_();
|
||||
fx.run_InitPragma(regy, pragma);
|
||||
} GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_(); GfmlTypRegy regy; GfmlPragmaVar pragma;
|
||||
@Test public void Text1() {
|
||||
@Test public void Text1() {
|
||||
GfmlNde gnde = fx.run_Resolve(regy, "_var/text"
|
||||
, fx.nde_().Atru_("key_test").Atru_("val_test").Atru_("context_test"));
|
||||
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z482_vars_parse_tst {
|
||||
GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_var:{"
|
||||
, " size '20,20';"
|
||||
@@ -27,7 +27,7 @@ public class z482_vars_parse_tst {
|
||||
, fx.nde_().Atru_("20,20")
|
||||
);
|
||||
}
|
||||
@Test public void Many() {
|
||||
@Test public void Many() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_var:{"
|
||||
, " size '20,20';"
|
||||
@@ -38,7 +38,7 @@ public class z482_vars_parse_tst {
|
||||
, fx.nde_().Atru_("20,20").Atru_("30,30")
|
||||
);
|
||||
}
|
||||
@Test public void Deferred() {
|
||||
@Test public void Deferred() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_var:{"
|
||||
, " key0 '<~key1>';"
|
||||
@@ -51,7 +51,7 @@ public class z482_vars_parse_tst {
|
||||
, fx.nde_().Atru_("val1")
|
||||
);
|
||||
}
|
||||
@Test public void Swap() {
|
||||
@Test public void Swap() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "{"
|
||||
, " _var:{"
|
||||
@@ -70,7 +70,7 @@ public class z482_vars_parse_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Context() {
|
||||
@Test public void Context() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_var:{"
|
||||
, " size '20,20' gui;"
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z501_lxr_parse_tst {
|
||||
GfmlTypeCompiler_fxt fx = GfmlTypeCompiler_fxt.new_();
|
||||
@Test public void SymCreate() {
|
||||
@Test public void SymCreate() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_lxr_sym:key='gfml.elm_key_1' raw='<-' cmd='gfml.elm_key';"
|
||||
, "a<-1;"
|
||||
@@ -25,7 +25,7 @@ public class z501_lxr_parse_tst {
|
||||
, fx.nde_().Atrk_("a", "1")
|
||||
);
|
||||
}
|
||||
@Test public void SymUpdate() {
|
||||
@Test public void SymUpdate() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_lxr_sym:key='gfml.elm_key_0' raw='<-';"
|
||||
, "a<-1 b=1;"
|
||||
@@ -33,7 +33,7 @@ public class z501_lxr_parse_tst {
|
||||
, fx.nde_().Atrk_("a", "1").Atru_("b=1")
|
||||
);
|
||||
}
|
||||
@Test public void SwapCreate() {
|
||||
@Test public void SwapCreate() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_lxr_sym:key='gfml.swap_0' raw='/?/?' val='/?';"
|
||||
, "/?/?;"
|
||||
@@ -41,7 +41,7 @@ public class z501_lxr_parse_tst {
|
||||
, fx.nde_().Atru_("/?")
|
||||
);
|
||||
}
|
||||
@Test public void FrameCreate() {
|
||||
@Test public void FrameCreate() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_lxr_frame:key='gfml.comment_2' type='comment' bgn='/-' end='-/';"
|
||||
, "a=/-ignore-/b;"
|
||||
@@ -49,7 +49,7 @@ public class z501_lxr_parse_tst {
|
||||
, fx.nde_().Atrk_("a", "b")
|
||||
);
|
||||
}
|
||||
@Test public void FrameUpdate() {
|
||||
@Test public void FrameUpdate() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "_lxr_frame:key='gfml.comment_0' bgn='--' end='!';"
|
||||
, "a=--ignore!"
|
||||
@@ -75,7 +75,7 @@ public class z501_lxr_parse_tst {
|
||||
// how to change inner lxrs (lookup by key?)
|
||||
}
|
||||
|
||||
// @Test public void FrameUpdateEval() {
|
||||
// @Test public void FrameUpdateEval() {
|
||||
// raw = String_.Concat
|
||||
// ( "_lxr_frame:key='gfml.eval_0' bgn='~<' end='>';" // how to handle '<~' where <~ (block quote)
|
||||
// , "a=~[t];"
|
||||
|
||||
@@ -1,75 +1,75 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z601_edit_atr_tst {
|
||||
GfmlUpdateFx fx = GfmlUpdateFx.new_();
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
fx .Raw_("a=1;").Update_(fx.atr_().NdeIdxs_(0).Atr_("a", "2"))
|
||||
.tst_("a=2;");
|
||||
}
|
||||
@Test public void WhiteSpaceComment() {
|
||||
@Test public void WhiteSpaceComment() {
|
||||
fx .Raw_("a = /*comment*/1;").Update_(fx.atr_().NdeIdxs_(0).Atr_("a", "2"))
|
||||
.tst_("a = /*comment*/2;");
|
||||
}
|
||||
@Test public void Quoted() {
|
||||
@Test public void Quoted() {
|
||||
fx .Raw_("a='1';").Update_(fx.atr_().NdeIdxs_(0).Atr_("a", "2"))
|
||||
.tst_("a='2';");
|
||||
}
|
||||
@Test public void EmbeddedQuote() {
|
||||
@Test public void EmbeddedQuote() {
|
||||
fx .Raw_("a=1;").Update_(fx.atr_().NdeIdxs_(0).Atr_("a", "1'2"))
|
||||
.tst_("a='1''2';");
|
||||
}
|
||||
@Test public void ReuseQuote() {
|
||||
@Test public void ReuseQuote() {
|
||||
fx .Raw_("a=|'1'|;").Update_(fx.atr_().NdeIdxs_(0).Atr_("a", "2"))
|
||||
.tst_("a=|'2'|;");
|
||||
}
|
||||
@Test public void ReuseQuoteWithEmbeddedQuote() {
|
||||
@Test public void ReuseQuoteWithEmbeddedQuote() {
|
||||
fx .Raw_("a=|'1'2'|;").Update_(fx.atr_().NdeIdxs_(0).Atr_("a", "2'3"))
|
||||
.tst_("a=|'2'3'|;");
|
||||
}
|
||||
// @Test public void AtrIdx() {
|
||||
// @Test public void AtrIdx() {
|
||||
// fx .Raw_("1;").Update_(fx.atr_().NdeIdxs_(0).AtrIdx_(0, "2"))
|
||||
// .tst_("2;");
|
||||
// }
|
||||
// @Test public void AtrIdx_parens() {
|
||||
// @Test public void AtrIdx_parens() {
|
||||
// fx .Raw_("A_('1');").Update_(fx.atr_().NdeIdxs_(0).AtrIdx_(0, "2"))
|
||||
// .tst_("A_('2');");
|
||||
// }
|
||||
@Test public void AddNew() {
|
||||
@Test public void AddNew() {
|
||||
fx .Raw_("a:;").Update_(fx.atr_().NdeIdxs_(0).Atr_("b", "1"))
|
||||
.tst_("a:b='1';");
|
||||
}
|
||||
@Test public void AddExisting() {
|
||||
@Test public void AddExisting() {
|
||||
fx .Raw_("a='1';").Update_(fx.atr_().NdeIdxs_(0).Atr_("b", "2"))
|
||||
.tst_("a='1' b='2';");
|
||||
}
|
||||
@Test public void Add_many() {
|
||||
@Test public void Add_many() {
|
||||
fx .Raw_("a='1';").Update_(fx.atr_().NdeIdxs_(0).Atr_("b", "2")).Update_(fx.atr_().NdeIdxs_(0).Atr_("c", "3"))
|
||||
.tst_("a='1' b='2' c='3';");
|
||||
}
|
||||
@Test public void AddNode() {
|
||||
@Test public void AddNode() {
|
||||
fx .Raw_("a(){}").Update_(fx.nde_().NdeIdxs_(0).Nest_("b"))
|
||||
.tst_("a(){b(){}}");
|
||||
}
|
||||
@Test public void AddNodeMany() {
|
||||
@Test public void AddNodeMany() {
|
||||
fx .Raw_("a(){}").Update_(fx.nde_().NdeIdxs_(0).Nest_("b")).Update_(fx.nde_().NdeIdxs_(0).Nest_("c"))
|
||||
.tst_("a(){b(){}c(){}}");
|
||||
}
|
||||
@Test public void EditNode() {
|
||||
@Test public void EditNode() {
|
||||
fx .Raw_("a(){b(){}}").Update_(fx.nde_().NdeIdxs_(0).Nest_("b"))
|
||||
.tst_("a(){b(){}}");
|
||||
}
|
||||
|
||||
@@ -13,10 +13,10 @@ The terms of each license can be found in the source code repository:
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z602_edit_nde_tst {
|
||||
GfmlUpdateFx fx = GfmlUpdateFx.new_();
|
||||
@Test public void Basic() {
|
||||
}
|
||||
}
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z602_edit_nde_tst {
|
||||
GfmlUpdateFx fx = GfmlUpdateFx.new_();
|
||||
@Test public void Basic() {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
import gplx.core.stores.*;
|
||||
public class z801_useCase_DataRdr_tst {
|
||||
String raw;
|
||||
@Test public void Subs_byName() {
|
||||
@Test public void Subs_byName() {
|
||||
raw = String_.Concat
|
||||
( "_type:{"
|
||||
, " item {"
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z803_useCase_KbdKeyboard_tst {
|
||||
String raw; GfmlDoc gdoc;
|
||||
@Test public void Quote() { // smokeTest; make sure DefaultLxr supports both quoting mechanisms
|
||||
@Test public void Quote() { // smokeTest; make sure DefaultLxr supports both quoting mechanisms
|
||||
fx.tst_Parse(String_.Concat
|
||||
( "gfui-keyboard-ui:{"
|
||||
, " keyQuote {"
|
||||
@@ -34,7 +34,7 @@ public class z803_useCase_KbdKeyboard_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Key_LtrA() {
|
||||
@Test public void Key_LtrA() {
|
||||
fx.tst_Parse(String_.Concat
|
||||
( TypeHeader
|
||||
, "keys:{"
|
||||
@@ -52,7 +52,7 @@ public class z803_useCase_KbdKeyboard_tst {
|
||||
)
|
||||
);
|
||||
}
|
||||
@Test public void Load_Smoke() {
|
||||
@Test public void Load_Smoke() {
|
||||
Io_url url = Tfds.RscDir.GenSubFil_nest("110_gfml", "cfgs_archive", "gfui-keyboard-ui.cfg.gfml");
|
||||
raw = Io_mgr.Instance.LoadFilStr(url);
|
||||
gdoc = GfmlDoc_.parse_any_eol_(raw);
|
||||
|
||||
@@ -1,28 +1,28 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*;
|
||||
public class z811_useCase_GfmlIoSql_tst {
|
||||
@Test public void Basic() {
|
||||
@Test public void Basic() {
|
||||
tst_Doc("fld1=val1", nde_("fld").Atrs_add_("word", "fld1").Atrs_add_("op", "=").Atrs_add_("word", "val1"));
|
||||
tst_Doc("fld1 = val1", nde_("fld").Atrs_add_("word", "fld1").Atrs_add_("op", "=").Atrs_add_("word", "val1"));
|
||||
tst_Doc("fld1='val1'", nde_("fld").Atrs_add_("word", "fld1").Atrs_add_("op", "=").Atrs_add_("word", "val1"));
|
||||
tst_Doc("fld1='val 1'", nde_("fld").Atrs_add_("word", "fld1").Atrs_add_("op", "=").Atrs_add_("word", "val 1"));
|
||||
}
|
||||
@Test public void Basic2() {
|
||||
@Test public void Basic2() {
|
||||
tst_Doc("1=1 OR 2=2", nde_("fld").Atrs_add_("word", "1").Atrs_add_("op", "=").Atrs_add_("word", "1")
|
||||
.Atrs_add_("word", "OR")
|
||||
.Atrs_add_("word", "2").Atrs_add_("op", "=").Atrs_add_("word", "2")
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
/*
|
||||
XOWA: the XOWA Offline Wiki Application
|
||||
Copyright (C) 2012-2017 gnosygnu@gmail.com
|
||||
|
||||
XOWA is licensed under the terms of the General Public License (GPL) Version 3,
|
||||
or alternatively under the terms of the Apache License Version 2.0.
|
||||
|
||||
You may use XOWA according to either of these licenses as is most appropriate
|
||||
for your project on a case-by-case basis.
|
||||
|
||||
The terms of each license can be found in the source code repository:
|
||||
|
||||
GPLv3 License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-GPLv3.txt
|
||||
Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt
|
||||
*/
|
||||
package gplx.gfml; import gplx.*;
|
||||
import org.junit.*; import gplx.core.strings.*; import gplx.core.envs.*;
|
||||
public class z901_perf_tst {
|
||||
TimerWatch tmr = TimerWatch.new_();
|
||||
@Test public void EmptyTestSoJunitWillNotFail() {}
|
||||
@Test public void EmptyTestSoJunitWillNotFail() {}
|
||||
// @Test
|
||||
public void Long() {
|
||||
// String longText = String_.Repeat("a", 30 * 1000 * 1000);
|
||||
@@ -45,7 +45,7 @@ public class z901_perf_tst {
|
||||
GfmlDoc_.parse_any_eol_(sbGfml.To_str());
|
||||
tmr.End_and_print("gfml"); // 1700
|
||||
}
|
||||
//@Test
|
||||
//@Test
|
||||
public void Prop() {
|
||||
int max = 100 * 1000 * 1000;
|
||||
PerfFieldVsProc c = new PerfFieldVsProc();
|
||||
@@ -64,7 +64,7 @@ public class z901_perf_tst {
|
||||
tmr.End_and_print("proc");
|
||||
Tfds.Write(v);
|
||||
}
|
||||
// @Test
|
||||
// @Test
|
||||
// public void ClassComp() {
|
||||
// int max = 100 * 1000 * 1000;
|
||||
// ClassType ct = new ClassType3();
|
||||
|
||||
Reference in New Issue
Block a user