Debian Codegraph @

tests/yaml/precedence.yaml

raw symbols SCIP
1 # The purpose of this test is just to document the current behavior of
2 # Liblouis when a table contains conflicting rules. This might be
3 # different from the desired behavior.
4 # ---------------------------------------------
5
6 # last undefined rule wins
7 display: |
8 display 1 1
9 display 2 2
10 table: |
11 undefined 1
12 undefined 2
13 tests:
14 - [x, 2]
15
16 # the first character definition rule wins
17 display: |
18 display 1 1
19 display 2 2
20 display 3 3
21 table: |
22 sign P 1
23 sign P 2
24 sign P 3
25 flags: {testmode: forward}
26 tests:
27 - - "P"
28 - "1"
29
30 # ... also in compbrlAtCursor mode
31 # (original issue: see https://github.com/liblouis/liblouis/issues/869)
32 - - "P"
33 - "1"
34 - mode: [compbrlAtCursor]
35 cursorPos: [0,0]
36
37 # ... also if a context rule with * in the action part is matched
38 display: |
39 display 1 1
40 display 2 2
41 display 3 3
42 table: |
43 sign P 1
44 sign P 2
45 sign P 3
46 noback context ["P"] *
47 flags: {testmode: forward}
48 tests:
49 - - "P"
50 - "1"
51
52 # the first character definition rule wins
53 display: tables/unicode-without-blank.dis
54 table: |
55 include tables/spaces.uti
56 lowercase a 1
57 uppercase A 1
58 uppercase B 12
59 lowercase b 12
60 lowercase c 14
61 uppercase C 14
62 lowercase d 145
63 uppercase D 145
64 lowercase e 15
65 uppercase E 15
66 lowercase f 124
67 uppercase F 124
68 lowercase g 1245
69 uppercase G 1245
70 lowercase h 125
71 uppercase H 125
72 uppercase B 1
73 lowercase b 1
74 lowercase d 14
75 uppercase D 14
76 lowercase f 15
77 uppercase F 15
78 lowercase h 1245
79 uppercase H 1245
80 tests:
81 - - Aa Bb Cc Dd Ee Ff Gg Hh
82 - ⠁⠁ ⠃⠃ ⠉⠉ ⠙⠙ ⠑⠑ ⠋⠋ ⠛⠛ ⠓⠓
83
84 # if "X" is defined as "uppercase X ...", the first "uppercase X" wins
85 # if "X" is defined as "base uppercase X x", the first definition of "x" wins
86 # (original issue: https://github.com/liblouis/liblouis/issues/384)
87 display: tables/unicode-without-blank.dis
88 table: |
89 include tables/spaces.uti
90 lowercase a 1
91 base uppercase A a
92 uppercase B 12
93 lowercase b 12
94 lowercase c 14
95 base uppercase C c
96 lowercase d 145
97 base uppercase D d
98 lowercase e 15
99 base uppercase E e
100 lowercase f 124
101 base uppercase F f
102 lowercase g 1245
103 base uppercase G g
104 lowercase h 125
105 base uppercase H h
106 capsletter 6
107 uppercase B 1
108 lowercase b 1
109 lowercase d 14
110 lowercase f 15
111 lowercase h 1245
112 tests:
113 - - Aa Bb Cc Dd Ee Ff Gg Hh
114 - ⠠⠁⠁ ⠠⠃⠃ ⠠⠉⠉ ⠠⠙⠙ ⠠⠑⠑ ⠠⠋⠋ ⠠⠛⠛ ⠠⠓⠓
115 # same but without capsletter
116 display: tables/unicode-without-blank.dis
117 table: |
118 include tables/spaces.uti
119 lowercase a 1
120 base uppercase A a
121 uppercase B 12
122 lowercase b 12
123 lowercase c 14
124 base uppercase C c
125 lowercase d 145
126 base uppercase D d
127 lowercase e 15
128 base uppercase E e
129 lowercase f 124
130 base uppercase F f
131 lowercase g 1245
132 base uppercase G g
133 lowercase h 125
134 base uppercase H h
135 uppercase B 1
136 lowercase b 1
137 lowercase d 14
138 lowercase f 15
139 lowercase h 1245
140 tests:
141 - - Aa Bb Cc Dd Ee Ff Gg Hh
142 - ⠁⠁ ⠃⠃ ⠉⠉ ⠙⠙ ⠑⠑ ⠋⠋ ⠛⠛ ⠓⠓
143
144 # for printing escape sequences for undefined characters, only
145 # character definitions that map to a single dot are used and the
146 # first definition wins. display rules are ignored.
147 display: tables/unicode-without-blank.dis
148 table: |
149 include tables/unicode-without-blank.dis
150 digit 0 356
151 digit 2 23
152 digit 6 235
153 letter x 1346
154 sign \\ 16
155 sign ' 3-3
156 display ' 6
157 sign ' 3
158 sign ' 6
159 flags: {testmode: forward}
160 tests:
161 - - "\u2026"
162 - ⠄⠡⠭⠆⠴⠆⠖⠄