metanorma-standoc 1.8.8 → 1.9.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,38 +1,38 @@
1
1
  require "spec_helper"
2
2
 
3
3
  RSpec.describe Asciidoctor::Standoc do
4
- it "handles spacing around markup" do
4
+ it "handles spacing around markup" do
5
5
  expect((strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to (<<~"OUTPUT")
6
6
  #{ASCIIDOC_BLANK_HDR}
7
7
  This is
8
8
  a paragraph with <<x>>
9
9
  markup _for_
10
10
  text, including **__nest__**ed markup.
11
- INPUT
12
- <?xml version="1.0" encoding="UTF-8"?>
13
- <standard-document xmlns="https://www.metanorma.org/ns/standoc" type="semantic" version="#{Metanorma::Standoc::VERSION}">
14
- <bibdata type="standard">
15
- <title language="en" format="text/plain">Document title</title>
16
- <language>en</language>
17
- <script>Latn</script>
18
- <status>
19
- <stage>published</stage>
20
- </status>
21
- <copyright>
22
- <from>#{Date.today.year}</from>
23
- </copyright>
24
- <ext>
25
- <doctype>article</doctype>
26
- </ext>
27
- </bibdata>
28
- <sections>
29
- <p id="_">This is
30
- a paragraph with <xref target="x"/>
31
- markup <em>for</em>
32
- text, including <strong><em>nest</em></strong>ed markup.</p>
33
- </sections>
34
- </standard-document>
35
- OUTPUT
11
+ INPUT
12
+ <?xml version="1.0" encoding="UTF-8"?>
13
+ <standard-document xmlns="https://www.metanorma.org/ns/standoc" type="semantic" version="#{Metanorma::Standoc::VERSION}">
14
+ <bibdata type="standard">
15
+ <title language="en" format="text/plain">Document title</title>
16
+ <language>en</language>
17
+ <script>Latn</script>
18
+ <status>
19
+ <stage>published</stage>
20
+ </status>
21
+ <copyright>
22
+ <from>#{Date.today.year}</from>
23
+ </copyright>
24
+ <ext>
25
+ <doctype>article</doctype>
26
+ </ext>
27
+ </bibdata>
28
+ <sections>
29
+ <p id="_">This is
30
+ a paragraph with <xref target="x"/>
31
+ markup <em>for</em>
32
+ text, including <strong><em>nest</em></strong>ed markup.</p>
33
+ </sections>
34
+ </standard-document>
35
+ OUTPUT
36
36
  end
37
37
 
38
38
  it "processes inline_quoted formatting" do
@@ -57,27 +57,27 @@ text, including <strong><em>nest</em></strong>ed markup.</p>
57
57
  [smallcap]#smallcap#
58
58
  [keyword]#keyword#
59
59
  INPUT
60
- #{BLANK_HDR}
61
- <sections>
62
- <em>Physical noise sources</em>
63
- <strong>strong</strong>
64
- <tt>monospace</tt>
65
- "double quote"
66
- 'single quote'
67
- super<sup>script</sup>
68
- sub<sub>script</sub>
69
- sub<sub><em>scr</em>ipt</sub>
70
- <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><msub> <mrow> <mrow> <mi mathvariant="bold-italic">F</mi> </mrow> </mrow> <mrow> <mrow> <mi mathvariant="bold-italic">Α</mi> </mrow> </mrow> </msub> </math></stem>
71
- mark
72
- <admitted>alt</admitted>
73
- <deprecates>deprecated</deprecates>
74
- <domain>domain</domain>
75
- <strike>strike</strike>
76
- <underline>underline</underline>
77
- <smallcap>smallcap</smallcap>
78
- <keyword>keyword</keyword>
79
- </sections>
80
- </standard-document>
60
+ #{BLANK_HDR}
61
+ <sections>
62
+ <em>Physical noise sources</em>
63
+ <strong>strong</strong>
64
+ <tt>monospace</tt>
65
+ "double quote"
66
+ 'single quote'
67
+ super<sup>script</sup>
68
+ sub<sub>script</sub>
69
+ sub<sub><em>scr</em>ipt</sub>
70
+ <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><msub> <mrow> <mrow> <mi mathvariant="bold-italic">F</mi> </mrow> </mrow> <mrow> <mrow> <mi mathvariant="bold-italic">Α</mi> </mrow> </mrow> </msub> </math></stem>
71
+ mark
72
+ <admitted>alt</admitted>
73
+ <deprecates>deprecated</deprecates>
74
+ <domain>domain</domain>
75
+ <strike>strike</strike>
76
+ <underline>underline</underline>
77
+ <smallcap>smallcap</smallcap>
78
+ <keyword>keyword</keyword>
79
+ </sections>
80
+ </standard-document>
81
81
  OUTPUT
82
82
  end
83
83
 
@@ -86,22 +86,22 @@ text, including <strong><em>nest</em></strong>ed markup.</p>
86
86
  #{DUMBQUOTE_BLANK_HDR}
87
87
 
88
88
  stem:[n < 1 " for all text "]
89
- INPUT
90
- #{BLANK_HDR}
91
- <sections>
92
- <p id='_'>
93
- <stem type='MathML'>
94
- <math xmlns='http://www.w3.org/1998/Math/MathML'>
95
- <mi>n</mi>
96
- <mo/>
97
- <mn>1</mn>
98
- <mtext> for all text </mtext>
99
- </math>
100
- </stem>
101
- </p>
102
- </sections>
103
- </standard-document>
104
- OUTPUT
89
+ INPUT
90
+ #{BLANK_HDR}
91
+ <sections>
92
+ <p id='_'>
93
+ <stem type='MathML'>
94
+ <math xmlns='http://www.w3.org/1998/Math/MathML'>
95
+ <mi>n</mi>
96
+ <mo/>
97
+ <mn>1</mn>
98
+ <mtext> for all text </mtext>
99
+ </math>
100
+ </stem>
101
+ </p>
102
+ </sections>
103
+ </standard-document>
104
+ OUTPUT
105
105
  end
106
106
 
107
107
  it "properly handles inline substitution" do
@@ -111,36 +111,36 @@ OUTPUT
111
111
  stem:[n < 1] +
112
112
  latexmath:[n < 1]
113
113
  stem:["&#x200c;"^199 "Hg"^+]
114
- INPUT
115
- #{BLANK_HDR}
116
- <sections>
117
- <p id="_">
118
- <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>n</mi><mo>&lt;</mo><mn>1</mn></math></stem><br/>
119
- <stem type="MathML"> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>n</mi> <mo>&lt;</mo> <mn>1</mn> </mrow> </math></stem>
120
- <stem type='MathML'>
121
- <math xmlns='http://www.w3.org/1998/Math/MathML'>
122
- <msup>
123
- <mrow>
124
- <mtext>‌</mtext>
125
- </mrow>
126
- <mrow>
127
- <mn>199</mn>
128
- </mrow>
129
- </msup>
130
- <msup>
131
- <mrow>
132
- <mtext>Hg</mtext>
133
- </mrow>
134
- <mrow>
135
- <mo>+</mo>
136
- </mrow>
137
- </msup>
138
- </math>
139
- </stem>
140
- </p>
141
- </sections>
142
- </standard-document>
143
- OUTPUT
114
+ INPUT
115
+ #{BLANK_HDR}
116
+ <sections>
117
+ <p id="_">
118
+ <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>n</mi><mo>&lt;</mo><mn>1</mn></math></stem><br/>
119
+ <stem type="MathML"> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>n</mi> <mo>&lt;</mo> <mn>1</mn> </mrow> </math></stem>
120
+ <stem type='MathML'>
121
+ <math xmlns='http://www.w3.org/1998/Math/MathML'>
122
+ <msup>
123
+ <mrow>
124
+ <mtext>‌</mtext>
125
+ </mrow>
126
+ <mrow>
127
+ <mn>199</mn>
128
+ </mrow>
129
+ </msup>
130
+ <msup>
131
+ <mrow>
132
+ <mtext>Hg</mtext>
133
+ </mrow>
134
+ <mrow>
135
+ <mo>+</mo>
136
+ </mrow>
137
+ </msup>
138
+ </math>
139
+ </stem>
140
+ </p>
141
+ </sections>
142
+ </standard-document>
143
+ OUTPUT
144
144
  end
145
145
 
146
146
  it "normalises inline stem, straight quotes" do
@@ -150,36 +150,36 @@ OUTPUT
150
150
  stem:[n < 1]
151
151
  latexmath:[n < 1]
152
152
  stem:["&#x200c;"^199 "Hg"^+]
153
- INPUT
154
- #{BLANK_HDR}
155
- <sections>
156
- <p id="_">
157
- <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>n</mi><mo>&lt;</mo><mn>1</mn></math></stem>
158
- <stem type="MathML"> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>n</mi> <mo>&lt;</mo> <mn>1</mn> </mrow> </math></stem>
159
- <stem type='MathML'>
160
- <math xmlns='http://www.w3.org/1998/Math/MathML'>
161
- <msup>
162
- <mrow>
163
- <mtext>‌</mtext>
164
- </mrow>
165
- <mrow>
166
- <mn>199</mn>
167
- </mrow>
168
- </msup>
169
- <msup>
170
- <mrow>
171
- <mtext>Hg</mtext>
172
- </mrow>
173
- <mrow>
174
- <mo>+</mo>
175
- </mrow>
176
- </msup>
177
- </math>
178
- </stem>
179
- </p>
180
- </sections>
181
- </standard-document>
182
- OUTPUT
153
+ INPUT
154
+ #{BLANK_HDR}
155
+ <sections>
156
+ <p id="_">
157
+ <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>n</mi><mo>&lt;</mo><mn>1</mn></math></stem>
158
+ <stem type="MathML"> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>n</mi> <mo>&lt;</mo> <mn>1</mn> </mrow> </math></stem>
159
+ <stem type='MathML'>
160
+ <math xmlns='http://www.w3.org/1998/Math/MathML'>
161
+ <msup>
162
+ <mrow>
163
+ <mtext>‌</mtext>
164
+ </mrow>
165
+ <mrow>
166
+ <mn>199</mn>
167
+ </mrow>
168
+ </msup>
169
+ <msup>
170
+ <mrow>
171
+ <mtext>Hg</mtext>
172
+ </mrow>
173
+ <mrow>
174
+ <mo>+</mo>
175
+ </mrow>
176
+ </msup>
177
+ </math>
178
+ </stem>
179
+ </p>
180
+ </sections>
181
+ </standard-document>
182
+ OUTPUT
183
183
  end
184
184
 
185
185
  it "normalises inline stem, smart quotes" do
@@ -189,53 +189,51 @@ OUTPUT
189
189
  stem:[n < 1]
190
190
  latexmath:[n < 1]
191
191
  stem:["&#x200c;"^199 "Hg"^+]
192
- INPUT
193
- #{BLANK_HDR}
194
- <sections>
195
- <p id="_">
196
- <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>n</mi><mo>&lt;</mo><mn>1</mn></math></stem>
197
- <stem type="MathML"> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>n</mi> <mo>&lt;</mo> <mn>1</mn> </mrow> </math></stem>
198
- <stem type='MathML'>
199
- <math xmlns='http://www.w3.org/1998/Math/MathML'>
200
- <msup>
201
- <mrow>
202
- <mtext>‌</mtext>
203
- </mrow>
204
- <mrow>
205
- <mn>199</mn>
206
- </mrow>
207
- </msup>
208
- <msup>
209
- <mrow>
210
- <mtext>Hg</mtext>
211
- </mrow>
212
- <mrow>
213
- <mo>+</mo>
214
- </mrow>
215
- </msup>
216
- </math>
217
- </stem>
218
- </p>
219
- </sections>
220
- </standard-document>
221
- OUTPUT
192
+ INPUT
193
+ #{BLANK_HDR}
194
+ <sections>
195
+ <p id="_">
196
+ <stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>n</mi><mo>&lt;</mo><mn>1</mn></math></stem>
197
+ <stem type="MathML"> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>n</mi> <mo>&lt;</mo> <mn>1</mn> </mrow> </math></stem>
198
+ <stem type='MathML'>
199
+ <math xmlns='http://www.w3.org/1998/Math/MathML'>
200
+ <msup>
201
+ <mrow>
202
+ <mtext>‌</mtext>
203
+ </mrow>
204
+ <mrow>
205
+ <mn>199</mn>
206
+ </mrow>
207
+ </msup>
208
+ <msup>
209
+ <mrow>
210
+ <mtext>Hg</mtext>
211
+ </mrow>
212
+ <mrow>
213
+ <mo>+</mo>
214
+ </mrow>
215
+ </msup>
216
+ </math>
217
+ </stem>
218
+ </p>
219
+ </sections>
220
+ </standard-document>
221
+ OUTPUT
222
222
  end
223
223
 
224
-
225
224
  it "generates desired smart quotes for 'dd'" do
226
225
  expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
227
226
  #{ASCIIDOC_BLANK_HDR}
228
227
  '99'.
229
228
 
230
229
  INPUT
231
- #{BLANK_HDR}
232
- <sections><p id="_">‘99’.</p>
233
- </sections>
234
- </standard-document>
230
+ #{BLANK_HDR}
231
+ <sections><p id="_">‘99’.</p>
232
+ </sections>
233
+ </standard-document>
235
234
  OUTPUT
236
235
  end
237
236
 
238
-
239
237
  it "processes breaks" do
240
238
  expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
241
239
  #{ASCIIDOC_BLANK_HDR}
@@ -252,15 +250,15 @@ OUTPUT
252
250
  [%portrait]
253
251
  <<<
254
252
  INPUT
255
- #{BLANK_HDR}
256
- <sections><p id="_">Line break<br/>
257
- line break</p>
258
- <hr/>
259
- <pagebreak/>
260
- <pagebreak orientation="landscape"/>
261
- <pagebreak orientation="portrait"/>
262
- </sections>
263
- </standard-document>
253
+ #{BLANK_HDR}
254
+ <sections><p id="_">Line break<br/>
255
+ line break</p>
256
+ <hr/>
257
+ <pagebreak/>
258
+ <pagebreak orientation="landscape"/>
259
+ <pagebreak orientation="portrait"/>
260
+ </sections>
261
+ </standard-document>
264
262
  OUTPUT
265
263
  end
266
264
 
@@ -273,34 +271,34 @@ OUTPUT
273
271
  http://example.com[Link,title="tip"]
274
272
  link:++https://asciidoctor.org/now_this__link_works.html++[]
275
273
  INPUT
276
- #{BLANK_HDR}
277
- <sections>
278
- <p id="_">mailto:fred@example.com
279
- <link target="http://example.com"/>
280
- <link target="http://example.com">Link</link>
281
- <link target="http://example.com" alt="tip">Link</link>
282
- <link target='https://asciidoctor.org/now_this__link_works.html'/>
283
- </p>
284
- </sections>
285
- </standard-document>
274
+ #{BLANK_HDR}
275
+ <sections>
276
+ <p id="_">mailto:fred@example.com
277
+ <link target="http://example.com"/>
278
+ <link target="http://example.com">Link</link>
279
+ <link target="http://example.com" alt="tip">Link</link>
280
+ <link target='https://asciidoctor.org/now_this__link_works.html'/>
281
+ </p>
282
+ </sections>
283
+ </standard-document>
286
284
  OUTPUT
287
285
  end
288
286
 
289
- it "processes bookmarks" do
287
+ it "processes bookmarks" do
290
288
  expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
291
289
  #{ASCIIDOC_BLANK_HDR}
292
290
  Text [[bookmark]] Text
293
291
  INPUT
294
- #{BLANK_HDR}
295
- <sections>
296
- <p id="_">Text <bookmark id="bookmark"/> Text</p>
297
- </sections>
298
- </standard-document>
292
+ #{BLANK_HDR}
293
+ <sections>
294
+ <p id="_">Text <bookmark id="bookmark"/> Text</p>
295
+ </sections>
296
+ </standard-document>
299
297
  OUTPUT
300
- end
298
+ end
301
299
 
302
- it "processes crossreferences" do
303
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
300
+ it "processes crossreferences" do
301
+ expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
304
302
  #{ASCIIDOC_BLANK_HDR}
305
303
  [[reference]]
306
304
  == Section
@@ -318,39 +316,42 @@ OUTPUT
318
316
  Lowercase Footnoted Reference to <<reference,droploc%fn>>
319
317
  Capitalised Reference to <<reference,droploc%capital%>>
320
318
  Lowercase Footnoted Reference to <<reference,droploc%capital%fn>>
319
+ Lowercase Footnoted Reference to <<reference,droploc%capital%text>>
321
320
  INPUT
322
- #{BLANK_HDR}
323
- <sections>
324
- <clause id="reference" inline-header="false" obligation="normative">
325
- <title>Section</title>
326
- <p id="_">Inline Reference to <xref target="reference"/>
327
- Footnoted Reference to <xref target="reference"/>
328
- Inline Reference with Text to <xref target="reference">text</xref>
329
- Footnoted Reference with Text to <xref target="reference">text</xref>
330
- Anchored Crossreference to other document <xref target="a#b"/>
331
- Capitalised Reference to <xref target='reference' case='capital' droploc="true"></xref>
332
- Lowercase Footnoted Reference to <xref target='reference' case='capital' droploc="true"></xref>
333
- Capitalised Reference to
334
- <xref target='reference' case='capital'/>
335
- Lowercase Footnoted Reference to
336
- <xref target='reference' case='capital'/>
337
- Capitalised Reference to
338
- <xref target='reference' droploc='true'/>
339
- Lowercase Footnoted Reference to
340
- <xref target='reference' droploc='true'/>
341
- Capitalised Reference to
342
- <xref target='reference' case='capital' droploc='true'/>
343
- Lowercase Footnoted Reference to
344
- <xref target='reference' case='capital' droploc='true'/>
345
- </p>
346
- </clause>
347
- </sections>
348
- </standard-document>
349
- OUTPUT
350
- end
321
+ #{BLANK_HDR}
322
+ <sections>
323
+ <clause id="reference" inline-header="false" obligation="normative">
324
+ <title>Section</title>
325
+ <p id="_">Inline Reference to <xref target="reference"/>
326
+ Footnoted Reference to <xref target="reference"/>
327
+ Inline Reference with Text to <xref target="reference">text</xref>
328
+ Footnoted Reference with Text to <xref target="reference">text</xref>
329
+ Anchored Crossreference to other document <xref target="a#b"/>
330
+ Capitalised Reference to <xref target='reference' case='capital' droploc="true"></xref>
331
+ Lowercase Footnoted Reference to <xref target='reference' case='capital' droploc="true"></xref>
332
+ Capitalised Reference to
333
+ <xref target='reference' case='capital'/>
334
+ Lowercase Footnoted Reference to
335
+ <xref target='reference' case='capital'/>
336
+ Capitalised Reference to
337
+ <xref target='reference' droploc='true'/>
338
+ Lowercase Footnoted Reference to
339
+ <xref target='reference' droploc='true'/>
340
+ Capitalised Reference to
341
+ <xref target='reference' case='capital' droploc='true'/>
342
+ Lowercase Footnoted Reference to
343
+ <xref target='reference' case='capital' droploc='true'/>
344
+ Lowercase Footnoted Reference to
345
+ <xref target='reference' case='capital' droploc='true'>text</xref>
346
+ </p>
347
+ </clause>
348
+ </sections>
349
+ </standard-document>
350
+ OUTPUT
351
+ end
351
352
 
352
- it "processes bibliographic anchors" do
353
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
353
+ it "processes bibliographic anchors" do
354
+ expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
354
355
  #{ASCIIDOC_BLANK_HDR}
355
356
  [bibliography]
356
357
  == Normative References
@@ -359,29 +360,29 @@ OUTPUT
359
360
  * [[[ISO713]]] Reference
360
361
 
361
362
  INPUT
362
- #{BLANK_HDR}
363
- <sections>
363
+ #{BLANK_HDR}
364
+ <sections>
364
365
 
365
- </sections><bibliography><references id="_" obligation="informative" normative="true">
366
- <title>Normative references</title>
367
- <p id="_">The following documents are referred to in the text in such a way that some or all of their content constitutes requirements of this document. For dated references, only the edition cited applies. For undated references, the latest edition of the referenced document (including any amendments) applies.</p>
368
- <bibitem id="ISO712">
369
- <formattedref format="application/x-isodoc+xml">Reference</formattedref>
370
- <docidentifier>x</docidentifier>
371
- </bibitem>
372
- <bibitem id="ISO713">
373
- <formattedref format="application/x-isodoc+xml">Reference</formattedref>
374
- <docidentifier>ISO713</docidentifier>
375
- <docnumber>713</docnumber>
376
- </bibitem>
377
- </references>
378
- </bibliography>
379
- </standard-document>
366
+ </sections><bibliography><references id="_" obligation="informative" normative="true">
367
+ <title>Normative references</title>
368
+ <p id="_">The following documents are referred to in the text in such a way that some or all of their content constitutes requirements of this document. For dated references, only the edition cited applies. For undated references, the latest edition of the referenced document (including any amendments) applies.</p>
369
+ <bibitem id="ISO712">
370
+ <formattedref format="application/x-isodoc+xml">Reference</formattedref>
371
+ <docidentifier>x</docidentifier>
372
+ </bibitem>
373
+ <bibitem id="ISO713">
374
+ <formattedref format="application/x-isodoc+xml">Reference</formattedref>
375
+ <docidentifier>ISO713</docidentifier>
376
+ <docnumber>713</docnumber>
377
+ </bibitem>
378
+ </references>
379
+ </bibliography>
380
+ </standard-document>
380
381
  OUTPUT
381
382
  end
382
383
 
383
384
  it "processes footnotes" do
384
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
385
+ expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
385
386
  #{ASCIIDOC_BLANK_HDR}
386
387
  Hello!footnote:[Footnote text]
387
388
 
@@ -389,48 +390,46 @@ OUTPUT
389
390
 
390
391
  Hello.footnote:abc[This is a repeated footnote]
391
392
 
392
- Repetition.footnote:abc[]
393
+ Repetition.footnote:abc[]
393
394
  INPUT
394
- #{BLANK_HDR}
395
- <preface><foreword id="_" obligation="informative">
396
- <title>Foreword</title>
397
- <p id="_">Hello!<fn reference="1">
398
- <p id="_">Footnote text</p>
399
- </fn></p>
400
- </foreword></preface><sections>
401
- <clause id="_" inline-header="false" obligation="normative">
402
- <title>Title<fn reference="2">
403
- <p id="_">Footnote text 2</p>
404
- </fn></title>
405
- <p id='_'>
406
- Hello.
407
- <fn reference='3'>
408
- <p id='_'>This is a repeated footnote</p>
409
- </fn>
410
- </p>
411
- <p id='_'>
412
- Repetition.
413
- <fn reference='3'>
414
- <p id='_'>This is a repeated footnote</p>
415
- </fn>
416
- </p>
417
- </clause></sections>
418
- </standard-document>
395
+ #{BLANK_HDR}
396
+ <preface><foreword id="_" obligation="informative">
397
+ <title>Foreword</title>
398
+ <p id="_">Hello!<fn reference="1">
399
+ <p id="_">Footnote text</p>
400
+ </fn></p>
401
+ </foreword></preface><sections>
402
+ <clause id="_" inline-header="false" obligation="normative">
403
+ <title>Title<fn reference="2">
404
+ <p id="_">Footnote text 2</p>
405
+ </fn></title>
406
+ <p id='_'>
407
+ Hello.
408
+ <fn reference='3'>
409
+ <p id='_'>This is a repeated footnote</p>
410
+ </fn>
411
+ </p>
412
+ <p id='_'>
413
+ Repetition.
414
+ <fn reference='3'>
415
+ <p id='_'>This is a repeated footnote</p>
416
+ </fn>
417
+ </p>
418
+ </clause></sections>
419
+ </standard-document>
419
420
  OUTPUT
420
421
  end
421
422
 
422
- it "processes index terms" do
423
- expect((strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to (<<~"OUTPUT")
423
+ it "processes index terms" do
424
+ expect((strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :standoc, header_footer: true)))).to be_equivalent_to (<<~"OUTPUT")
424
425
  #{ASCIIDOC_BLANK_HDR}
425
426
  ((See)) Index ((_term_)) and(((A~B~, stem:[alpha], &#x2c80;))).
426
- INPUT
427
- #{BLANK_HDR}
428
- <sections>
429
- <p id="_">See<index><primary>See</primary></index> Index <em>term</em><index><primary><em>term</em></primary></index> and<index><primary>A<sub>B</sub></primary><secondary><stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>α</mi></math></stem></secondary><tertiary>Ⲁ</tertiary></index>.</p>
430
- </sections>
431
- </standard-document>
432
- OUTPUT
427
+ INPUT
428
+ #{BLANK_HDR}
429
+ <sections>
430
+ <p id="_">See<index><primary>See</primary></index> Index <em>term</em><index><primary><em>term</em></primary></index> and<index><primary>A<sub>B</sub></primary><secondary><stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>α</mi></math></stem></secondary><tertiary>Ⲁ</tertiary></index>.</p>
431
+ </sections>
432
+ </standard-document>
433
+ OUTPUT
433
434
  end
434
-
435
-
436
435
  end