Skip to content

Commit

Permalink
#11: added test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
fititnt committed Nov 28, 2021
1 parent 2ee571d commit 2b79de7
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 3 deletions.
2 changes: 2 additions & 0 deletions docs/eng-Latn/hxltm.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ hxltmdexml --agendum-linguam lat-Latn,arb-Arab testum/hxltm-salve-mundi.hxltm.xm
hxltmcli --agendum-linguam eng-Latn@en,por-Latn@pt hxl-non-hxltm-exemplum.hxl.csv
linguacodex --de_codex por-Latn-g-port1283-t-eng --de_bcp47_simplex | jq
////
[source,bash]
----
Expand Down
2 changes: 1 addition & 1 deletion testum/de-extraneum/hxltm-bi-linguam-in-columnam.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
id,source language,target language,source term,target term
codicem,source language,target language,source term,target term
#item+conceptum+codicem,#item+terminum+est_linguam_fontem,#item+terminum+est_linguam_objectivum,#item+terminum+de_linguam_fontem,#item+terminum+de_linguam_objectivum
1,eng-Latn,por-Latn,UN,ONU
2,eng-Latn,por-Latn,United Nations,Organização das Nações Unidas
Expand Down
14 changes: 14 additions & 0 deletions testum/de-extraneum/hxltm-multi-linguam-in-columnam-v.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
codicem,linguam maximum codicem,linguam (HXL attributum),linguam,Glottocode,BCP47 code,BCP47 transformed (RFC 6497),ISO 15924 alpha code,terminum
#item+conceptum+codicem,#item+terminum+est_linguam+v_linguam_maximum,#item+terminum+est_linguam+v_linguam_a,#item+terminum+est_linguam+v_linguam,#item+terminum+est_linguam+v_glotto,#item+terminum+est_linguam+v_bc47,#item+terminum+est_linguam+v_bc47_t,#item+terminum+est_linguam+v_iso15924a,#item+terminum+de_linguam
1,eng-Latn-g-stan1293,i_en+i_eng+ig_stan1293+is_latn,eng-Latn,stan1293,en,en,Latn,UN
2,eng-Latn-g-stan1293,i_en+i_eng+ig_stan1293+is_latn,eng-Latn,stan1293,en,en,Latn,United Nations
3,eng-Latn-g-stan1293,i_en+i_eng+ig_stan1293+is_latn,eng-Latn,stan1293,en,en,Latn,IFRC
4,eng-Latn-g-stan1293,i_en+i_eng+ig_stan1293+is_latn,eng-Latn,stan1293,en,en,Latn,International Federation of Red Cross and Red Crescent Societies
5,eng-Latn-g-stan1293,i_en+i_eng+ig_stan1293+is_latn,eng-Latn,stan1293,en,en,Latn,AI
6,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,Amnistia Internacional
1,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,ONU
2,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,Organização das Nações Unidas
3,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,FICV/CV
4,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,Federação Internacional das Sociedades da Cruz Vermelha e do Crescente Vermelho
5,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,AI
6,por-Latn-g-port1283-t-eng,i_pt+i_por+ig_port1283+is_latn,por-Latn,port1283,pt,pt-t-en,Latn,Amnistia Internacional
2 changes: 1 addition & 1 deletion testum/de-extraneum/hxltm-multi-linguam-in-columnam.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
id,lang,term
codicem,linguam,term
#item+conceptum+codicem,#item+terminum+est_linguam,#item+terminum+de_linguam
1,eng-Latn,UN
2,eng-Latn,United Nations
Expand Down
2 changes: 1 addition & 1 deletion testum/de-extraneum/hxltm-solum-id.tm.hxl.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
id
codicem
#item+conceptum+codicem
1
2
Expand Down
5 changes: 5 additions & 0 deletions testum/disciplinam-manuale-anglicum.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ hxltmdexml --help > "hxltmdexml--help_eng-Latn.txt"
# fi
### TODO: implement some way to also validate all CSVs on folder

# To validate all CSVs
# csvlint from https://github.com/Clever/csvlint/
# find . -iname "*.csv" -type f -exec echo "{}" \;
# find . -iname "*.csv" -type f -exec echo "{}" \; -exec csvlint "{}" \;


# tag::HXLStandard_examples[]
### I -------------------------------------------------------------------------
Expand Down

0 comments on commit 2b79de7

Please sign in to comment.