metanorma-standoc 1.10.8 → 1.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +1 -1
  3. data/lib/asciidoctor/standoc/base.rb +5 -4
  4. data/lib/asciidoctor/standoc/blocks.rb +1 -1
  5. data/lib/asciidoctor/standoc/cleanup.rb +20 -11
  6. data/lib/asciidoctor/standoc/cleanup_boilerplate.rb +28 -20
  7. data/lib/asciidoctor/standoc/cleanup_inline.rb +20 -7
  8. data/lib/asciidoctor/standoc/cleanup_maths.rb +5 -6
  9. data/lib/asciidoctor/standoc/cleanup_ref_dl.rb +25 -15
  10. data/lib/asciidoctor/standoc/cleanup_reqt.rb +2 -21
  11. data/lib/asciidoctor/standoc/cleanup_section_names.rb +2 -2
  12. data/lib/asciidoctor/standoc/cleanup_symbols.rb +48 -0
  13. data/lib/asciidoctor/standoc/cleanup_terms.rb +54 -79
  14. data/lib/asciidoctor/standoc/cleanup_terms_designations.rb +179 -0
  15. data/lib/asciidoctor/standoc/cleanup_text.rb +23 -0
  16. data/lib/asciidoctor/standoc/converter.rb +2 -0
  17. data/lib/asciidoctor/standoc/datamodel/attributes_table_preprocessor.rb +6 -6
  18. data/lib/asciidoctor/standoc/inline.rb +20 -16
  19. data/lib/asciidoctor/standoc/isodoc.rng +254 -27
  20. data/lib/asciidoctor/standoc/lists.rb +1 -3
  21. data/lib/asciidoctor/standoc/macros_plantuml.rb +29 -14
  22. data/lib/asciidoctor/standoc/macros_terms.rb +49 -5
  23. data/lib/asciidoctor/standoc/ref.rb +101 -75
  24. data/lib/asciidoctor/standoc/ref_date_id.rb +30 -1
  25. data/lib/asciidoctor/standoc/ref_sect.rb +42 -24
  26. data/lib/asciidoctor/standoc/reqt.rb +1 -1
  27. data/lib/asciidoctor/standoc/section.rb +14 -13
  28. data/lib/asciidoctor/standoc/term_lookup_cleanup.rb +50 -11
  29. data/lib/asciidoctor/standoc/terms.rb +12 -2
  30. data/lib/asciidoctor/standoc/utils.rb +36 -23
  31. data/lib/asciidoctor/standoc/validate.rb +25 -16
  32. data/lib/isodoc/html/htmlstyle.css +1 -1
  33. data/lib/isodoc/html/htmlstyle.scss +1 -1
  34. data/lib/metanorma/standoc/version.rb +1 -1
  35. data/metanorma-standoc.gemspec +3 -3
  36. data/spec/asciidoctor/base_spec.rb +4 -3
  37. data/spec/asciidoctor/blocks_spec.rb +202 -21
  38. data/spec/asciidoctor/cleanup_sections_spec.rb +7 -7
  39. data/spec/asciidoctor/cleanup_spec.rb +23 -197
  40. data/spec/asciidoctor/cleanup_terms_spec.rb +1205 -0
  41. data/spec/asciidoctor/datamodel/attributes_table_preprocessor_spec.rb +21 -21
  42. data/spec/asciidoctor/datamodel/diagram_preprocessor_spec.rb +16 -16
  43. data/spec/asciidoctor/inline_spec.rb +7 -7
  44. data/spec/asciidoctor/isobib_cache_spec.rb +4 -8
  45. data/spec/asciidoctor/macros_plantuml_spec.rb +36 -1
  46. data/spec/asciidoctor/macros_spec.rb +189 -112
  47. data/spec/asciidoctor/refs_dl_spec.rb +4 -4
  48. data/spec/asciidoctor/refs_spec.rb +860 -522
  49. data/spec/asciidoctor/section_spec.rb +18 -18
  50. data/spec/asciidoctor/validate_spec.rb +59 -2
  51. data/spec/spec_helper.rb +3 -2
  52. data/spec/vcr_cassettes/dated_iso_ref_joint_iso_iec.yml +180 -180
  53. data/spec/vcr_cassettes/dated_iso_ref_joint_iso_iec1.yml +12 -12
  54. data/spec/vcr_cassettes/isobib_get_123.yml +12 -12
  55. data/spec/vcr_cassettes/isobib_get_123_1.yml +27 -27
  56. data/spec/vcr_cassettes/isobib_get_123_1_fr.yml +35 -35
  57. data/spec/vcr_cassettes/isobib_get_123_2001.yml +13 -13
  58. data/spec/vcr_cassettes/isobib_get_124.yml +12 -12
  59. data/spec/vcr_cassettes/rfcbib_get_rfc8341.yml +14 -14
  60. data/spec/vcr_cassettes/separates_iev_citations_by_top_level_clause.yml +45 -65
  61. metadata +11 -8
@@ -4,7 +4,7 @@ require "relaton_ietf"
4
4
 
5
5
  RSpec.describe Asciidoctor::Standoc do
6
6
  it "processes simple ISO reference" do
7
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
7
+ input = <<~INPUT
8
8
  #{ASCIIDOC_BLANK_HDR}
9
9
  [bibliography]
10
10
  == Normative References
@@ -12,6 +12,7 @@ RSpec.describe Asciidoctor::Standoc do
12
12
  * [[[iso123,ISO 123]]] _Standard_
13
13
  * [[[iso124,(1)ISO 123]]] _Standard_
14
14
  INPUT
15
+ output = <<~OUTPUT
15
16
  #{BLANK_HDR}
16
17
  <sections>
17
18
  </sections><bibliography><references id="_" obligation="informative" normative="true">
@@ -44,10 +45,12 @@ RSpec.describe Asciidoctor::Standoc do
44
45
  </bibliography>
45
46
  </standard-document>
46
47
  OUTPUT
48
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
49
+ .to be_equivalent_to xmlpp(output)
47
50
  end
48
51
 
49
52
  it "processes simple ISO reference with date range" do
50
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
53
+ input = <<~INPUT
51
54
  #{ASCIIDOC_BLANK_HDR}
52
55
  [bibliography]
53
56
  == Normative References
@@ -55,6 +58,7 @@ RSpec.describe Asciidoctor::Standoc do
55
58
  * [[[iso123,ISO 123:1066-1067]]] _Standard_
56
59
  * [[[iso124,(1)ISO 123:1066-1067]]] _Standard_
57
60
  INPUT
61
+ output = <<~OUTPUT
58
62
  #{BLANK_HDR}
59
63
  <sections>
60
64
  </sections><bibliography><references id="_" obligation="informative" normative="true">
@@ -96,6 +100,8 @@ RSpec.describe Asciidoctor::Standoc do
96
100
  </bibliography>
97
101
  </standard-document>
98
102
  OUTPUT
103
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
104
+ .to be_equivalent_to xmlpp(output)
99
105
  end
100
106
 
101
107
  it "repairs simple fetched ISO reference" do
@@ -113,118 +119,122 @@ RSpec.describe Asciidoctor::Standoc do
113
119
  * [[[iso123,ISO 123]]] _Standard_
114
120
  * [[[iso124,(1)ISO 123]]] _Standard_
115
121
  INPUT
116
- expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
117
- #{BLANK_HDR}
118
- <preface>
119
- <foreword id='_' obligation='informative'>
120
- <title>Foreword</title>
121
- <p id='_'>
122
- <eref type='inline' bibitemid='iso123' citeas='ISO 123'/>
123
- <eref type='inline' bibitemid='iso124' citeas='[1]'/>
124
- </p>
125
- </foreword>
126
- </preface>
127
- <sections>
128
- </sections><bibliography><references id="_" obligation="informative" normative="true"><title>Normative references</title>
129
- #{NORM_REF_BOILERPLATE}
130
- <bibitem type="standard" id="iso123">
131
- <uri type="src">https://www.iso.org/standard/23281.html</uri>
132
- <uri type="obp">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
133
- <uri type="rss">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
134
- <date type="published">
135
- <on>2001</on>
136
- </date>
137
- <contributor>
138
- <role type="publisher"/>
139
- <organization>
140
- <name>International Organization for Standardization</name>
141
- <abbreviation>ISO</abbreviation>
142
- <uri>www.iso.org</uri>
143
- </organization>
144
- </contributor>
145
- <edition>3</edition>
146
- <language>en</language>
147
- <language>fr</language>
148
- <script>Latn</script>
149
- <status>
150
- <stage>Published</stage>
151
- </status>
152
- <copyright>
153
- <from>2001</from>
154
- <owner>
122
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
123
+ .to be_equivalent_to xmlpp(<<~"OUTPUT")
124
+ #{BLANK_HDR}
125
+ <preface>
126
+ <foreword id='_' obligation='informative'>
127
+ <title>Foreword</title>
128
+ <p id='_'>
129
+ <eref type='inline' bibitemid='iso123' citeas='ISO 123'/>
130
+ <eref type='inline' bibitemid='iso124' citeas='[1]'/>
131
+ </p>
132
+ </foreword>
133
+ </preface>
134
+ <sections>
135
+ </sections><bibliography><references id="_" obligation="informative" normative="true"><title>Normative references</title>
136
+ #{NORM_REF_BOILERPLATE}
137
+ <bibitem type="standard" id="iso123">
138
+ <uri type="src">https://www.iso.org/standard/23281.html</uri>
139
+ <uri type="obp">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
140
+ <uri type="rss">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
141
+ <date type="published">
142
+ <on>2001</on>
143
+ </date>
144
+ <contributor>
145
+ <role type="publisher"/>
155
146
  <organization>
156
- <name>ISO</name>
157
- <abbreviation/>
147
+ <name>International Organization for Standardization</name>
148
+ <abbreviation>ISO</abbreviation>
149
+ <uri>www.iso.org</uri>
158
150
  </organization>
159
- </owner>
160
- </copyright>
161
- <relation type="obsoletes">
162
- <bibitem type="standard">
163
- <formattedref format="text/plain">ISO 123:1985</formattedref>
164
- </bibitem>
165
- </relation>
166
- <relation type="updates">
167
- <bibitem type="standard">
168
- <formattedref format="text/plain">ISO 123:2001</formattedref>
169
- </bibitem>
170
- </relation>
171
- <docidentifier>ISO 123</docidentifier>
172
- <title><em>Standard</em></title>
173
- </bibitem>
174
- <bibitem type="standard" id="iso124">
175
- <uri type="src">https://www.iso.org/standard/23281.html</uri>
176
- <uri type="obp">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
177
- <uri type="rss">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
178
- <date type="published">
179
- <on>2001</on>
180
- </date>
181
- <contributor>
182
- <role type="publisher"/>
183
- <organization>
184
- <name>International Organization for Standardization</name>
185
- <abbreviation>ISO</abbreviation>
186
- <uri>www.iso.org</uri>
187
- </organization>
188
- </contributor>
189
- <edition>3</edition>
190
- <language>en</language>
191
- <language>fr</language>
192
- <script>Latn</script>
193
- <status>
194
- <stage>Published</stage>
195
- </status>
196
- <copyright>
197
- <from>2001</from>
198
- <owner>
151
+ </contributor>
152
+ <edition>3</edition>
153
+ <language>en</language>
154
+ <language>fr</language>
155
+ <script>Latn</script>
156
+ <status>
157
+ <stage>Published</stage>
158
+ </status>
159
+ <copyright>
160
+ <from>2001</from>
161
+ <owner>
162
+ <organization>
163
+ <name>ISO</name>
164
+ <abbreviation/>
165
+ </organization>
166
+ </owner>
167
+ </copyright>
168
+ <relation type="obsoletes">
169
+ <bibitem type="standard">
170
+ <formattedref format="text/plain">ISO 123:1985</formattedref>
171
+ </bibitem>
172
+ </relation>
173
+ <relation type="updates">
174
+ <bibitem type="standard">
175
+ <formattedref format="text/plain">ISO 123:2001</formattedref>
176
+ </bibitem>
177
+ </relation>
178
+ <docidentifier>ISO 123</docidentifier>
179
+ <title><em>Standard</em></title>
180
+ </bibitem>
181
+ <bibitem type="standard" id="iso124">
182
+ <uri type="src">https://www.iso.org/standard/23281.html</uri>
183
+ <uri type="obp">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
184
+ <uri type="rss">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
185
+ <date type="published">
186
+ <on>2001</on>
187
+ </date>
188
+ <contributor>
189
+ <role type="publisher"/>
199
190
  <organization>
200
- <name>ISO</name>
201
- <abbreviation/>
191
+ <name>International Organization for Standardization</name>
192
+ <abbreviation>ISO</abbreviation>
193
+ <uri>www.iso.org</uri>
202
194
  </organization>
203
- </owner>
204
- </copyright>
205
- <relation type="obsoletes">
206
- <bibitem type="standard">
207
- <formattedref format="text/plain">ISO 123:1985</formattedref>
208
- </bibitem>
209
- </relation>
210
- <relation type="updates">
211
- <bibitem type="standard">
212
- <formattedref format="text/plain">ISO 123:2001</formattedref>
213
- </bibitem>
214
- </relation>
215
- <docidentifier>ISO 123</docidentifier>
216
- <docidentifier type='metanorma'>[1]</docidentifier>
217
- <title><em>Standard</em></title>
218
- </bibitem>
219
- </references></bibliography>
220
- </standard-document>
221
- OUTPUT
222
- expect { Asciidoctor.convert(input, *OPTIONS) }.to output(/ERROR: No document identifier retrieved for ISO 123/).to_stderr
195
+ </contributor>
196
+ <edition>3</edition>
197
+ <language>en</language>
198
+ <language>fr</language>
199
+ <script>Latn</script>
200
+ <status>
201
+ <stage>Published</stage>
202
+ </status>
203
+ <copyright>
204
+ <from>2001</from>
205
+ <owner>
206
+ <organization>
207
+ <name>ISO</name>
208
+ <abbreviation/>
209
+ </organization>
210
+ </owner>
211
+ </copyright>
212
+ <relation type="obsoletes">
213
+ <bibitem type="standard">
214
+ <formattedref format="text/plain">ISO 123:1985</formattedref>
215
+ </bibitem>
216
+ </relation>
217
+ <relation type="updates">
218
+ <bibitem type="standard">
219
+ <formattedref format="text/plain">ISO 123:2001</formattedref>
220
+ </bibitem>
221
+ </relation>
222
+ <docidentifier>ISO 123</docidentifier>
223
+ <docidentifier type='metanorma'>[1]</docidentifier>
224
+ <title><em>Standard</em></title>
225
+ </bibitem>
226
+ </references></bibliography>
227
+ </standard-document>
228
+ OUTPUT
229
+ expect do
230
+ Asciidoctor.convert(input, *OPTIONS)
231
+ end.to output(/ERROR: No document identifier retrieved for ISO 123/)
232
+ .to_stderr
223
233
  end
224
234
 
225
235
  it "fetches simple ISO reference" do
226
236
  VCR.use_cassette "isobib_get_123_1" do
227
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
237
+ input = <<~INPUT
228
238
  #{ISOBIB_BLANK_HDR}
229
239
  [bibliography]
230
240
  == Normative References
@@ -232,124 +242,213 @@ RSpec.describe Asciidoctor::Standoc do
232
242
  * [[[iso123,ISO 123]]] _Standard_
233
243
  * [[[iso124,(1)ISO 123]]] _Standard_
234
244
  INPUT
235
- #{BLANK_HDR}
236
- <sections>
245
+ output = <<~OUTPUT
246
+ #{BLANK_HDR}
247
+ <sections>
237
248
 
238
- </sections><bibliography><references id="_" obligation="informative" normative="true"><title>Normative references</title>
239
- #{NORM_REF_BOILERPLATE}
240
- <bibitem id='iso123' type='standard'>
241
- <fetched>#{Date.today}</fetched>
242
- <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
243
- <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
244
- <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
245
- <uri type='src'>https://www.iso.org/standard/23281.html</uri>
246
- <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
247
- <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
248
- <docidentifier type='ISO'>ISO 123:2001</docidentifier>
249
- <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
250
- <docnumber>123</docnumber>
251
- <date type='published'>
252
- <on>2001-05</on>
253
- </date>
254
- <contributor>
255
- <role type='publisher'/>
256
- <organization>
257
- <name>International Organization for Standardization</name>
258
- <abbreviation>ISO</abbreviation>
259
- <uri>www.iso.org</uri>
260
- </organization>
261
- </contributor>
262
- <edition>3</edition>
263
- <language>en</language>
264
- <script>Latn</script>
265
- <abstract format='text/plain' language='en' script='Latn'>
266
- This International Standard specifies procedures for sampling natural
267
- rubber latex concentrate and for sampling synthetic rubber latices and
268
- artificial latices. It is also suitable for sampling rubber latex
269
- contained in drums, tank cars or tanks. The procedures may also be
270
- used for sampling plastics dispersions.
271
- </abstract>
272
- <status>
273
- <stage>90</stage>
274
- <substage>93</substage>
275
- </status>
276
- <copyright>
277
- <from>2001</from>
278
- <owner>
279
- <organization>
280
- <name>ISO</name>
281
- </organization>
282
- </owner>
283
- </copyright>
284
- <relation type='obsoletes'>
285
- <bibitem type='standard'>
286
- <formattedref format='text/plain'>ISO 123:1985</formattedref>
287
- </bibitem>
288
- </relation>
289
- <place>Geneva</place>
290
- </bibitem>
291
- <bibitem id='iso124' type='standard'>
292
- <fetched>#{Date.today}</fetched>
293
- <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
294
- <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
295
- <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
296
- <uri type='src'>https://www.iso.org/standard/23281.html</uri>
297
- <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
298
- <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
299
- <docidentifier type='ISO'>ISO 123:2001</docidentifier>
300
- <docidentifier type='metanorma'>[1]</docidentifier>
301
- <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
302
- <docnumber>123</docnumber>
303
- <date type='published'>
304
- <on>2001-05</on>
305
- </date>
306
- <contributor>
307
- <role type='publisher'/>
308
- <organization>
309
- <name>International Organization for Standardization</name>
310
- <abbreviation>ISO</abbreviation>
311
- <uri>www.iso.org</uri>
312
- </organization>
313
- </contributor>
314
- <edition>3</edition>
315
- <language>en</language>
316
- <script>Latn</script>
317
- <abstract format='text/plain' language='en' script='Latn'>
318
- This International Standard specifies procedures for sampling natural
319
- rubber latex concentrate and for sampling synthetic rubber latices and
320
- artificial latices. It is also suitable for sampling rubber latex
321
- contained in drums, tank cars or tanks. The procedures may also be
322
- used for sampling plastics dispersions.
323
- </abstract>
324
- <status>
325
- <stage>90</stage>
326
- <substage>93</substage>
327
- </status>
328
- <copyright>
329
- <from>2001</from>
330
- <owner>
331
- <organization>
332
- <name>ISO</name>
333
- </organization>
334
- </owner>
335
- </copyright>
336
- <relation type='obsoletes'>
337
- <bibitem type='standard'>
338
- <formattedref format='text/plain'>ISO 123:1985</formattedref>
339
- </bibitem>
340
- </relation>
341
- <place>Geneva</place>
342
- </bibitem>
343
- </references>
344
- </bibliography>
345
- </standard-document>
249
+ </sections><bibliography><references id="_" obligation="informative" normative="true"><title>Normative references</title>
250
+ #{NORM_REF_BOILERPLATE}
251
+ <bibitem id='iso123' type='standard'>
252
+ <fetched/>
253
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
254
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
255
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
256
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
257
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
258
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
259
+ <docidentifier type='ISO'>ISO 123</docidentifier>
260
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
261
+ <docnumber>123</docnumber>
262
+ <contributor>
263
+ <role type='publisher'/>
264
+ <organization>
265
+ <name>International Organization for Standardization</name>
266
+ <abbreviation>ISO</abbreviation>
267
+ <uri>www.iso.org</uri>
268
+ </organization>
269
+ </contributor>
270
+ <edition>3</edition>
271
+ <language>en</language>
272
+ <script>Latn</script>
273
+ <status>
274
+ <stage>90</stage>
275
+ <substage>93</substage>
276
+ </status>
277
+ <copyright>
278
+ <from>2001</from>
279
+ <owner>
280
+ <organization>
281
+ <name>ISO</name>
282
+ </organization>
283
+ </owner>
284
+ </copyright>
285
+ <relation type='obsoletes'>
286
+ <bibitem type='standard'>
287
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
288
+ </bibitem>
289
+ </relation>
290
+ <relation type='instance'>
291
+ <bibitem type='standard'>
292
+ <fetched/>
293
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
294
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
295
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
296
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
297
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
298
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
299
+ <docidentifier type='ISO'>ISO 123:2001</docidentifier>
300
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
301
+ <docnumber>123</docnumber>
302
+ <date type='published'>
303
+ <on>2001-05</on>
304
+ </date>
305
+ <contributor>
306
+ <role type='publisher'/>
307
+ <organization>
308
+ <name>International Organization for Standardization</name>
309
+ <abbreviation>ISO</abbreviation>
310
+ <uri>www.iso.org</uri>
311
+ </organization>
312
+ </contributor>
313
+ <edition>3</edition>
314
+ <language>en</language>
315
+ <script>Latn</script>
316
+ <abstract format='text/plain' language='en' script='Latn'>
317
+ This International Standard specifies procedures for sampling
318
+ natural rubber latex concentrate and for sampling synthetic rubber
319
+ latices and artificial latices. It is also suitable for sampling
320
+ rubber latex contained in drums, tank cars or tanks. The
321
+ procedures may also be used for sampling plastics dispersions.
322
+ </abstract>
323
+ <status>
324
+ <stage>90</stage>
325
+ <substage>93</substage>
326
+ </status>
327
+ <copyright>
328
+ <from>2001</from>
329
+ <owner>
330
+ <organization>
331
+ <name>ISO</name>
332
+ </organization>
333
+ </owner>
334
+ </copyright>
335
+ <relation type='obsoletes'>
336
+ <bibitem type='standard'>
337
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
338
+ </bibitem>
339
+ </relation>
340
+ <place>Geneva</place>
341
+ </bibitem>
342
+ </relation>
343
+ <place>Geneva</place>
344
+ </bibitem>
345
+ <bibitem id='iso124' type='standard'>
346
+ <fetched/>
347
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
348
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
349
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
350
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
351
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
352
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
353
+ <docidentifier type='ISO'>ISO 123</docidentifier>
354
+ <docidentifier type='metanorma'>[1]</docidentifier>
355
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
356
+ <docnumber>123</docnumber>
357
+ <contributor>
358
+ <role type='publisher'/>
359
+ <organization>
360
+ <name>International Organization for Standardization</name>
361
+ <abbreviation>ISO</abbreviation>
362
+ <uri>www.iso.org</uri>
363
+ </organization>
364
+ </contributor>
365
+ <edition>3</edition>
366
+ <language>en</language>
367
+ <script>Latn</script>
368
+ <status>
369
+ <stage>90</stage>
370
+ <substage>93</substage>
371
+ </status>
372
+ <copyright>
373
+ <from>2001</from>
374
+ <owner>
375
+ <organization>
376
+ <name>ISO</name>
377
+ </organization>
378
+ </owner>
379
+ </copyright>
380
+ <relation type='obsoletes'>
381
+ <bibitem type='standard'>
382
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
383
+ </bibitem>
384
+ </relation>
385
+ <relation type='instance'>
386
+ <bibitem type='standard'>
387
+ <fetched/>
388
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
389
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
390
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
391
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
392
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
393
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
394
+ <docidentifier type='ISO'>ISO 123:2001</docidentifier>
395
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
396
+ <docnumber>123</docnumber>
397
+ <date type='published'>
398
+ <on>2001-05</on>
399
+ </date>
400
+ <contributor>
401
+ <role type='publisher'/>
402
+ <organization>
403
+ <name>International Organization for Standardization</name>
404
+ <abbreviation>ISO</abbreviation>
405
+ <uri>www.iso.org</uri>
406
+ </organization>
407
+ </contributor>
408
+ <edition>3</edition>
409
+ <language>en</language>
410
+ <script>Latn</script>
411
+ <abstract format='text/plain' language='en' script='Latn'>
412
+ This International Standard specifies procedures for sampling
413
+ natural rubber latex concentrate and for sampling synthetic rubber
414
+ latices and artificial latices. It is also suitable for sampling
415
+ rubber latex contained in drums, tank cars or tanks. The
416
+ procedures may also be used for sampling plastics dispersions.
417
+ </abstract>
418
+ <status>
419
+ <stage>90</stage>
420
+ <substage>93</substage>
421
+ </status>
422
+ <copyright>
423
+ <from>2001</from>
424
+ <owner>
425
+ <organization>
426
+ <name>ISO</name>
427
+ </organization>
428
+ </owner>
429
+ </copyright>
430
+ <relation type='obsoletes'>
431
+ <bibitem type='standard'>
432
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
433
+ </bibitem>
434
+ </relation>
435
+ <place>Geneva</place>
436
+ </bibitem>
437
+ </relation>
438
+ <place>Geneva</place>
439
+ </bibitem>
440
+ </references>
441
+ </bibliography>
442
+ </standard-document>
346
443
  OUTPUT
444
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
445
+ .to be_equivalent_to xmlpp(output)
347
446
  end
348
447
  end
349
448
 
350
449
  it "fetches simple ISO reference in French" do
351
450
  VCR.use_cassette "isobib_get_123_1_fr" do
352
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
451
+ input = <<~INPUT
353
452
  = Document title
354
453
  Author
355
454
  :docfile: test.adoc
@@ -364,138 +463,233 @@ RSpec.describe Asciidoctor::Standoc do
364
463
  * [[[iso123,ISO 123]]] _Standard_
365
464
  * [[[iso124,(1)ISO 123]]] _Standard_
366
465
  INPUT
367
- #{BLANK_HDR.sub(%r{<language>en</language>}, '<language>fr</language>')}
368
- <sections>
369
- </sections><bibliography>
370
- <references id='_' normative='true' obligation='informative'>
371
- <title>Références normatives</title>
372
- <p id='_'>
373
- Les documents suivants cités dans le texte constituent, pour tout ou
374
- partie de leur contenu, des exigences du présent document. Pour les
375
- références datées, seule l’édition citée s’applique. Pour les références
376
- non datées, la dernière édition du document de référence s’applique (y
377
- compris les éventuels amendements).
378
- </p>
379
- <bibitem id='iso123' type='standard'>
380
- <fetched>#{Date.today}</fetched>
466
+ output = <<~OUTPUT
467
+ #{BLANK_HDR.sub(%r{<language>en</language>}, '<language>fr</language>')}
468
+ <sections> </sections>
469
+ <bibliography>
470
+ <references id='_' normative='true' obligation='informative'>
471
+ <title>R&#233;f&#233;rences normatives</title>
472
+ <p id='_'>
473
+ Les documents suivants cit&#233;s dans le texte constituent, pour tout
474
+ ou partie de leur contenu, des exigences du pr&#233;sent document. Pour
475
+ les r&#233;f&#233;rences dat&#233;es, seule l&#8217;&#233;dition
476
+ cit&#233;e s&#8217;applique. Pour les r&#233;f&#233;rences non
477
+ dat&#233;es, la derni&#232;re &#233;dition du document de
478
+ r&#233;f&#233;rence s&#8217;applique (y compris les &#233;ventuels
479
+ amendements).
480
+ </p>
481
+ <bibitem id='iso123' type='standard'>
482
+ <fetched/>
381
483
  <title type='title-intro' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc</title>
382
- <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
383
- <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
384
- <uri type='src'>https://www.iso.org/standard/23281.html</uri>
385
- <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
386
- <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
387
- <docidentifier type='ISO'>ISO 123:2001</docidentifier>
388
- <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:fr</docidentifier>
389
- <docnumber>123</docnumber>
390
- <date type='published'>
391
- <on>2001-05</on>
392
- </date>
393
- <contributor>
394
- <role type='publisher'/>
395
- <organization>
396
- <name>International Organization for Standardization</name>
397
- <abbreviation>ISO</abbreviation>
398
- <uri>www.iso.org</uri>
399
- </organization>
400
- </contributor>
401
- <edition>3</edition>
402
- <language>en</language>
403
- <language>fr</language>
404
- <script>Latn</script>
405
- <abstract format='text/plain' language='fr' script='Latn'>
406
- La pr&#233;sente Norme internationale sp&#233;cifie des m&#233;thodes
407
- d&#8217;&#233;chantillonnage pour des concentr&#233;s de latex de
408
- caoutchouc naturel et pour &#233;chantillonner des latex de caoutchouc
409
- synth&#233;tique et des latex artificiels. Elle s&#8217;applique
410
- &#233;galement &#224; l&#8217;&#233;chantillonnage de latex de
411
- caoutchouc contenus dans des f&#251;ts, citernes routi&#232;res ou de
412
- stockage. Le mode op&#233;ratoire peut aussi &#234;tre utilis&#233;
413
- pour l&#8217;&#233;chantillonnage de dispersions de plastiques.
414
- </abstract>
415
- <status>
416
- <stage>90</stage>
417
- <substage>93</substage>
418
- </status>
419
- <copyright>
420
- <from>2001</from>
421
- <owner>
422
- <organization>
423
- <name>ISO</name>
424
- </organization>
425
- </owner>
426
- </copyright>
427
- <relation type='obsoletes'>
428
- <bibitem type='standard'>
429
- <formattedref format='text/plain'>ISO 123:1985</formattedref>
430
- </bibitem>
431
- </relation>
432
- <place>Geneva</place>
433
- </bibitem>
434
- <bibitem id='iso124' type='standard'>
435
- <fetched>#{Date.today}</fetched>
436
- <title type='title-intro' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc</title>
437
- <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
438
- <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
439
- <uri type='src'>https://www.iso.org/standard/23281.html</uri>
440
- <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
441
- <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
442
- <docidentifier type='ISO'>ISO 123:2001</docidentifier>
443
- <docidentifier type='metanorma'>[1]</docidentifier>
444
- <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:fr</docidentifier>
445
- <docnumber>123</docnumber>
446
- <date type='published'>
447
- <on>2001-05</on>
448
- </date>
449
- <contributor>
450
- <role type='publisher'/>
451
- <organization>
452
- <name>International Organization for Standardization</name>
453
- <abbreviation>ISO</abbreviation>
454
- <uri>www.iso.org</uri>
455
- </organization>
456
- </contributor>
457
- <edition>3</edition>
458
- <language>en</language>
459
- <language>fr</language>
460
- <script>Latn</script>
461
- <abstract format='text/plain' language='fr' script='Latn'>
462
- La pr&#233;sente Norme internationale sp&#233;cifie des m&#233;thodes
463
- d&#8217;&#233;chantillonnage pour des concentr&#233;s de latex de
464
- caoutchouc naturel et pour &#233;chantillonner des latex de caoutchouc
465
- synth&#233;tique et des latex artificiels. Elle s&#8217;applique
466
- &#233;galement &#224; l&#8217;&#233;chantillonnage de latex de
467
- caoutchouc contenus dans des f&#251;ts, citernes routi&#232;res ou de
468
- stockage. Le mode op&#233;ratoire peut aussi &#234;tre utilis&#233;
469
- pour l&#8217;&#233;chantillonnage de dispersions de plastiques.
470
- </abstract>
471
- <status>
472
- <stage>90</stage>
473
- <substage>93</substage>
474
- </status>
475
- <copyright>
476
- <from>2001</from>
477
- <owner>
478
- <organization>
479
- <name>ISO</name>
480
- </organization>
481
- </owner>
482
- </copyright>
483
- <relation type='obsoletes'>
484
- <bibitem type='standard'>
485
- <formattedref format='text/plain'>ISO 123:1985</formattedref>
486
- </bibitem>
487
- </relation>
488
- <place>Geneva</place>
489
- </bibitem>
490
- </references>
491
- </bibliography>
492
- </standard-document>
484
+ <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
485
+ <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
486
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
487
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
488
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
489
+ <docidentifier type='ISO'>ISO 123</docidentifier>
490
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:fr</docidentifier>
491
+ <docnumber>123</docnumber>
492
+ <contributor>
493
+ <role type='publisher'/>
494
+ <organization>
495
+ <name>International Organization for Standardization</name>
496
+ <abbreviation>ISO</abbreviation>
497
+ <uri>www.iso.org</uri>
498
+ </organization>
499
+ </contributor>
500
+ <edition>3</edition>
501
+ <language>en</language>
502
+ <language>fr</language>
503
+ <script>Latn</script>
504
+ <status>
505
+ <stage>90</stage>
506
+ <substage>93</substage>
507
+ </status>
508
+ <copyright>
509
+ <from>2001</from>
510
+ <owner>
511
+ <organization>
512
+ <name>ISO</name>
513
+ </organization>
514
+ </owner>
515
+ </copyright>
516
+ <relation type='obsoletes'>
517
+ <bibitem type='standard'>
518
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
519
+ </bibitem>
520
+ </relation>
521
+ <relation type='instance'>
522
+ <bibitem type='standard'>
523
+ <fetched/>
524
+ <title type='title-intro' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc</title>
525
+ <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
526
+ <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
527
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
528
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
529
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
530
+ <docidentifier type='ISO'>ISO 123:2001</docidentifier>
531
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:fr</docidentifier>
532
+ <docnumber>123</docnumber>
533
+ <date type='published'>
534
+ <on>2001-05</on>
535
+ </date>
536
+ <contributor>
537
+ <role type='publisher'/>
538
+ <organization>
539
+ <name>International Organization for Standardization</name>
540
+ <abbreviation>ISO</abbreviation>
541
+ <uri>www.iso.org</uri>
542
+ </organization>
543
+ </contributor>
544
+ <edition>3</edition>
545
+ <language>en</language>
546
+ <language>fr</language>
547
+ <script>Latn</script>
548
+ <abstract format='text/plain' language='fr' script='Latn'>
549
+ La pr&#233;sente Norme internationale sp&#233;cifie des
550
+ m&#233;thodes d&#8217;&#233;chantillonnage pour des
551
+ concentr&#233;s de latex de caoutchouc naturel et pour
552
+ &#233;chantillonner des latex de caoutchouc synth&#233;tique et
553
+ des latex artificiels. Elle s&#8217;applique &#233;galement &#224;
554
+ l&#8217;&#233;chantillonnage de latex de caoutchouc contenus dans
555
+ des f&#251;ts, citernes routi&#232;res ou de stockage. Le mode
556
+ op&#233;ratoire peut aussi &#234;tre utilis&#233; pour
557
+ l&#8217;&#233;chantillonnage de dispersions de plastiques.
558
+ </abstract>
559
+ <status>
560
+ <stage>90</stage>
561
+ <substage>93</substage>
562
+ </status>
563
+ <copyright>
564
+ <from>2001</from>
565
+ <owner>
566
+ <organization>
567
+ <name>ISO</name>
568
+ </organization>
569
+ </owner>
570
+ </copyright>
571
+ <relation type='obsoletes'>
572
+ <bibitem type='standard'>
573
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
574
+ </bibitem>
575
+ </relation>
576
+ <place>Geneva</place>
577
+ </bibitem>
578
+ </relation>
579
+ <place>Geneva</place>
580
+ </bibitem>
581
+ <bibitem id='iso124' type='standard'>
582
+ <fetched/>
583
+ <title type='title-intro' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc</title>
584
+ <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
585
+ <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
586
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
587
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
588
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
589
+ <docidentifier type='ISO'>ISO 123</docidentifier>
590
+ <docidentifier type='metanorma'>[1]</docidentifier>
591
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:fr</docidentifier>
592
+ <docnumber>123</docnumber>
593
+ <contributor>
594
+ <role type='publisher'/>
595
+ <organization>
596
+ <name>International Organization for Standardization</name>
597
+ <abbreviation>ISO</abbreviation>
598
+ <uri>www.iso.org</uri>
599
+ </organization>
600
+ </contributor>
601
+ <edition>3</edition>
602
+ <language>en</language>
603
+ <language>fr</language>
604
+ <script>Latn</script>
605
+ <status>
606
+ <stage>90</stage>
607
+ <substage>93</substage>
608
+ </status>
609
+ <copyright>
610
+ <from>2001</from>
611
+ <owner>
612
+ <organization>
613
+ <name>ISO</name>
614
+ </organization>
615
+ </owner>
616
+ </copyright>
617
+ <relation type='obsoletes'>
618
+ <bibitem type='standard'>
619
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
620
+ </bibitem>
621
+ </relation>
622
+ <relation type='instance'>
623
+ <bibitem type='standard'>
624
+ <fetched/>
625
+ <title type='title-intro' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc</title>
626
+ <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
627
+ <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
628
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
629
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
630
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
631
+ <docidentifier type='ISO'>ISO 123:2001</docidentifier>
632
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:fr</docidentifier>
633
+ <docnumber>123</docnumber>
634
+ <date type='published'>
635
+ <on>2001-05</on>
636
+ </date>
637
+ <contributor>
638
+ <role type='publisher'/>
639
+ <organization>
640
+ <name>International Organization for Standardization</name>
641
+ <abbreviation>ISO</abbreviation>
642
+ <uri>www.iso.org</uri>
643
+ </organization>
644
+ </contributor>
645
+ <edition>3</edition>
646
+ <language>en</language>
647
+ <language>fr</language>
648
+ <script>Latn</script>
649
+ <abstract format='text/plain' language='fr' script='Latn'>
650
+ La pr&#233;sente Norme internationale sp&#233;cifie des
651
+ m&#233;thodes d&#8217;&#233;chantillonnage pour des
652
+ concentr&#233;s de latex de caoutchouc naturel et pour
653
+ &#233;chantillonner des latex de caoutchouc synth&#233;tique et
654
+ des latex artificiels. Elle s&#8217;applique &#233;galement &#224;
655
+ l&#8217;&#233;chantillonnage de latex de caoutchouc contenus dans
656
+ des f&#251;ts, citernes routi&#232;res ou de stockage. Le mode
657
+ op&#233;ratoire peut aussi &#234;tre utilis&#233; pour
658
+ l&#8217;&#233;chantillonnage de dispersions de plastiques.
659
+ </abstract>
660
+ <status>
661
+ <stage>90</stage>
662
+ <substage>93</substage>
663
+ </status>
664
+ <copyright>
665
+ <from>2001</from>
666
+ <owner>
667
+ <organization>
668
+ <name>ISO</name>
669
+ </organization>
670
+ </owner>
671
+ </copyright>
672
+ <relation type='obsoletes'>
673
+ <bibitem type='standard'>
674
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
675
+ </bibitem>
676
+ </relation>
677
+ <place>Geneva</place>
678
+ </bibitem>
679
+ </relation>
680
+ <place>Geneva</place>
681
+ </bibitem>
682
+ </references>
683
+ </bibliography>
684
+ </standard-document>
493
685
  OUTPUT
686
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
687
+ .to be_equivalent_to xmlpp(output)
494
688
  end
495
689
  end
496
690
 
497
691
  it "processes simple IEC reference" do
498
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
692
+ input = <<~INPUT
499
693
  #{ASCIIDOC_BLANK_HDR}
500
694
  [bibliography]
501
695
  == Normative References
@@ -503,6 +697,7 @@ RSpec.describe Asciidoctor::Standoc do
503
697
  * [[[iso123,IEC 123]]] _Standard_
504
698
  * [[[iso124,(1)IEC 123]]] _Standard_
505
699
  INPUT
700
+ output = <<~OUTPUT
506
701
  #{BLANK_HDR}
507
702
  <sections>
508
703
  </sections><bibliography><references id="_" obligation="informative" normative="true">
@@ -535,13 +730,13 @@ RSpec.describe Asciidoctor::Standoc do
535
730
  </bibliography>
536
731
  </standard-document>
537
732
  OUTPUT
733
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
734
+ .to be_equivalent_to xmlpp(output)
538
735
  end
539
736
 
540
737
  it "processes dated ISO reference and joint ISO/IEC references" do
541
- # mock_isobib_get_iec12382
542
- # mock_isobib_get_124
543
- VCR.use_cassette "dated_iso_ref_joint_iso_iec" do
544
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
738
+ VCR.use_cassette("dated_iso_ref_joint_iso_iec", match_requests_on: %i[method uri body]) do
739
+ input = <<~INPUT
545
740
  #{ISOBIB_BLANK_HDR}
546
741
  [bibliography]
547
742
  == Normative References
@@ -551,6 +746,7 @@ RSpec.describe Asciidoctor::Standoc do
551
746
  * [[[iso125,(1)ISO/IEC TR 12382:1992]]] _Standard_
552
747
  * [[[iso126,(1)ISO 124:2014]]] _Standard_
553
748
  INPUT
749
+ output = <<~OUTPUT
554
750
  #{BLANK_HDR}
555
751
  <sections>
556
752
 
@@ -558,7 +754,7 @@ RSpec.describe Asciidoctor::Standoc do
558
754
  <title>Normative references</title>
559
755
  #{NORM_REF_BOILERPLATE}
560
756
  <bibitem type="standard" id="iso123">
561
- <fetched>#{Date.today}</fetched>
757
+ <fetched/>
562
758
  <title type="title-main" format="text/plain" language="en" script="Latn">Permuted index of the vocabulary of information technology</title>
563
759
  <title type="main" format="text/plain" language="en" script="Latn">Permuted index of the vocabulary of information technology</title>
564
760
  <uri type="src">https://www.iso.org/standard/21071.html</uri>
@@ -605,7 +801,7 @@ RSpec.describe Asciidoctor::Standoc do
605
801
  <place>Geneva</place>
606
802
  </bibitem>
607
803
  <bibitem id="iso124" type="standard">
608
- <fetched>#{Date.today}</fetched>
804
+ <fetched/>
609
805
  <title type="title-intro" format="text/plain" language="en" script="Latn">Latex, rubber</title>
610
806
  <title type="title-main" format="text/plain" language="en" script="Latn">Determination of total solids content</title>
611
807
  <title type='main' format='text/plain' language='en' script='Latn'>Latex, rubber — Determination of total solids content</title>
@@ -650,7 +846,7 @@ RSpec.describe Asciidoctor::Standoc do
650
846
  <place>Geneva</place>
651
847
  </bibitem>
652
848
  <bibitem id="iso125" type="standard">
653
- <fetched>#{Date.today}</fetched>
849
+ <fetched/>
654
850
  <title type="title-main" format="text/plain" language="en" script="Latn">Permuted index of the vocabulary of information technology</title>
655
851
  <title type='main' format='text/plain' language='en' script='Latn'>Permuted index of the vocabulary of information technology</title>
656
852
  <uri type="src">https://www.iso.org/standard/21071.html</uri>
@@ -698,7 +894,7 @@ RSpec.describe Asciidoctor::Standoc do
698
894
  <place>Geneva</place>
699
895
  </bibitem>
700
896
  <bibitem id="iso126" type="standard">
701
- <fetched>#{Date.today}</fetched>
897
+ <fetched/>
702
898
  <title type="title-intro" format="text/plain" language="en" script="Latn">Latex, rubber</title>
703
899
  <title type="title-main" format="text/plain" language="en" script="Latn">Determination of total solids content</title>
704
900
  <title type='main' format='text/plain' language='en' script='Latn'>Latex, rubber — Determination of total solids content</title>
@@ -747,12 +943,14 @@ RSpec.describe Asciidoctor::Standoc do
747
943
  </standard-document>
748
944
 
749
945
  OUTPUT
946
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
947
+ .to be_equivalent_to xmlpp(output)
750
948
  end
751
949
  end
752
950
 
753
951
  it "declines to fetch individual references" do
754
952
  VCR.use_cassette "dated_iso_ref_joint_iso_iec1" do
755
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
953
+ input = <<~INPUT
756
954
  #{ISOBIB_BLANK_HDR}
757
955
  [bibliography]
758
956
  == Normative References
@@ -760,6 +958,7 @@ RSpec.describe Asciidoctor::Standoc do
760
958
  * [[[iso123,nofetch(ISO/IEC TR 12382:1992)]]] _Standard_
761
959
  * [[[iso124,ISO 124:2014]]] _Standard_
762
960
  INPUT
961
+ output = <<~OUTPUT
763
962
  #{BLANK_HDR}
764
963
  <sections>
765
964
 
@@ -774,7 +973,7 @@ RSpec.describe Asciidoctor::Standoc do
774
973
  <docnumber>12382:1992</docnumber>
775
974
  </bibitem>
776
975
  <bibitem id='iso124' type='standard'>
777
- <fetched>#{Date.today}</fetched>
976
+ <fetched/>
778
977
  <title type='title-intro' format='text/plain' language='en' script='Latn'>Latex, rubber</title>
779
978
  <title type='title-main' format='text/plain' language='en' script='Latn'>Determination of total solids content</title>
780
979
  <title type='main' format='text/plain' language='en' script='Latn'>Latex, rubber — Determination of total solids content</title>
@@ -820,13 +1019,15 @@ RSpec.describe Asciidoctor::Standoc do
820
1019
  </bibitem>
821
1020
  </references></bibliography></standard-document>
822
1021
  OUTPUT
1022
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1023
+ .to be_equivalent_to xmlpp(output)
823
1024
  end
824
1025
  end
825
1026
 
826
1027
  it "processes draft ISO reference" do
827
1028
  # stub_fetch_ref no_year: true, note: "The standard is in press"
828
1029
 
829
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1030
+ input = <<~INPUT
830
1031
  #{ASCIIDOC_BLANK_HDR}
831
1032
  [bibliography]
832
1033
  == Normative References
@@ -836,6 +1037,7 @@ RSpec.describe Asciidoctor::Standoc do
836
1037
  * [[[iso125,ISO 125:&ndash;]]], footnote:[The standard is in press] _Standard_
837
1038
  * [[[iso126,(1)ISO 123:--]]] _Standard_
838
1039
  INPUT
1040
+ output = <<~OUTPUT
839
1041
  #{BLANK_HDR}
840
1042
  <sections>
841
1043
  </sections><bibliography><references id="_" obligation="informative" normative="true">
@@ -904,12 +1106,14 @@ RSpec.describe Asciidoctor::Standoc do
904
1106
  </bibliography>
905
1107
  </standard-document>
906
1108
  OUTPUT
1109
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1110
+ .to be_equivalent_to xmlpp(output)
907
1111
  end
908
1112
 
909
1113
  it "processes all-parts ISO reference" do
910
1114
  # stub_fetch_ref(all_parts: true)
911
1115
 
912
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1116
+ input = <<~INPUT
913
1117
  #{ASCIIDOC_BLANK_HDR}
914
1118
  [bibliography]
915
1119
  == Normative References
@@ -917,6 +1121,7 @@ RSpec.describe Asciidoctor::Standoc do
917
1121
  * [[[iso123,ISO 123:1066 (all parts)]]] _Standard_
918
1122
  * [[[iso124,(1)ISO 123:1066 (all parts)]]] _Standard_
919
1123
  INPUT
1124
+ output = <<~OUTPUT
920
1125
  #{BLANK_HDR}
921
1126
  <sections>
922
1127
  </sections><bibliography><references id="_" obligation="informative" normative="true">
@@ -961,12 +1166,14 @@ RSpec.describe Asciidoctor::Standoc do
961
1166
  </bibliography>
962
1167
  </standard-document>
963
1168
  OUTPUT
1169
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1170
+ .to be_equivalent_to xmlpp(output)
964
1171
  end
965
1172
 
966
1173
  it "processes RFC reference in Normative References" do
967
1174
  # mock_rfcbib_get_rfc8341
968
1175
  VCR.use_cassette "rfcbib_get_rfc8341" do
969
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1176
+ input = <<~INPUT
970
1177
  #{ISOBIB_BLANK_HDR}
971
1178
  [bibliography]
972
1179
  == Normative References
@@ -978,6 +1185,7 @@ RSpec.describe Asciidoctor::Standoc do
978
1185
 
979
1186
  <<iso123>>
980
1187
  INPUT
1188
+ output = <<~OUTPUT
981
1189
  #{BLANK_HDR}
982
1190
  <sections>
983
1191
  <clause id="_" inline-header="false" obligation="normative">
@@ -990,7 +1198,7 @@ RSpec.describe Asciidoctor::Standoc do
990
1198
  <title>Normative references</title>
991
1199
  #{NORM_REF_BOILERPLATE}
992
1200
  <bibitem id='iso123' type='standard'>
993
- <fetched>#{Date.today}</fetched>
1201
+ <fetched/>
994
1202
  <title format='text/plain' language='en' script='Latn'>Network Configuration Access Control Model</title>
995
1203
  <uri type='xml'>
996
1204
  https://raw.githubusercontent.com/relaton/relaton-data-ietf/master/data/reference.RFC.8341.xml
@@ -999,6 +1207,7 @@ RSpec.describe Asciidoctor::Standoc do
999
1207
  <docidentifier type='IETF'>RFC 8341</docidentifier>
1000
1208
  <docidentifier type='rfc-anchor'>RFC8341</docidentifier>
1001
1209
  <docidentifier type='DOI'>10.17487/RFC8341</docidentifier>
1210
+ <docnumber>RFC8341</docnumber>
1002
1211
  <date type='published'>
1003
1212
  <on>2018-03</on>
1004
1213
  </date>
@@ -1008,12 +1217,6 @@ RSpec.describe Asciidoctor::Standoc do
1008
1217
  <name>
1009
1218
  <completename language='en'>A. Bierman</completename>
1010
1219
  </name>
1011
- <affiliation>
1012
- <organization>
1013
- <name>Internet Engineering Task Force</name>
1014
- <abbreviation>IETF</abbreviation>
1015
- </organization>
1016
- </affiliation>
1017
1220
  </person>
1018
1221
  </contributor>
1019
1222
  <contributor>
@@ -1022,12 +1225,6 @@ RSpec.describe Asciidoctor::Standoc do
1022
1225
  <name>
1023
1226
  <completename language='en'>M. Bjorklund</completename>
1024
1227
  </name>
1025
- <affiliation>
1026
- <organization>
1027
- <name>Internet Engineering Task Force</name>
1028
- <abbreviation>IETF</abbreviation>
1029
- </organization>
1030
- </affiliation>
1031
1228
  </person>
1032
1229
  </contributor>
1033
1230
  <contributor>
@@ -1039,7 +1236,8 @@ RSpec.describe Asciidoctor::Standoc do
1039
1236
  </contributor>
1040
1237
  <language>en</language>
1041
1238
  <script>Latn</script>
1042
- <abstract format='text/plain' language='en' script='Latn'>
1239
+ <abstract format='text/html' language='en' script='Latn'>
1240
+ <p id='_'>
1043
1241
  The standardization of network configuration interfaces for use with
1044
1242
  the Network Configuration Protocol (NETCONF) or the RESTCONF protocol
1045
1243
  requires a structured and secure operating environment that promotes
@@ -1047,7 +1245,8 @@ RSpec.describe Asciidoctor::Standoc do
1047
1245
  standard mechanisms to restrict NETCONF or RESTCONF protocol access
1048
1246
  for particular users to a preconfigured subset of all available
1049
1247
  NETCONF or RESTCONF protocol operations and content. This document
1050
- defines such an access control model.This document obsoletes RFC 6536.
1248
+ defines such an access control model.</p>
1249
+ <p id='_'>This document obsoletes RFC 6536.</p>
1051
1250
  </abstract>
1052
1251
  <series type='main'>
1053
1252
  <title format='text/plain' language='en' script='Latn'>STD</title>
@@ -1060,7 +1259,7 @@ RSpec.describe Asciidoctor::Standoc do
1060
1259
  <place>Fremont, CA</place>
1061
1260
  </bibitem>
1062
1261
  <bibitem id='iso124' type='standard'>
1063
- <fetched>#{Date.today}</fetched>
1262
+ <fetched/>
1064
1263
  <title format='text/plain' language='en' script='Latn'>Network Configuration Access Control Model</title>
1065
1264
  <uri type='xml'>
1066
1265
  https://raw.githubusercontent.com/relaton/relaton-data-ietf/master/data/reference.RFC.8341.xml
@@ -1070,6 +1269,7 @@ RSpec.describe Asciidoctor::Standoc do
1070
1269
  <docidentifier type='metanorma'>[1]</docidentifier>
1071
1270
  <docidentifier type='rfc-anchor'>RFC8341</docidentifier>
1072
1271
  <docidentifier type='DOI'>10.17487/RFC8341</docidentifier>
1272
+ <docnumber>RFC8341</docnumber>
1073
1273
  <date type='published'>
1074
1274
  <on>2018-03</on>
1075
1275
  </date>
@@ -1079,12 +1279,6 @@ RSpec.describe Asciidoctor::Standoc do
1079
1279
  <name>
1080
1280
  <completename language='en'>A. Bierman</completename>
1081
1281
  </name>
1082
- <affiliation>
1083
- <organization>
1084
- <name>Internet Engineering Task Force</name>
1085
- <abbreviation>IETF</abbreviation>
1086
- </organization>
1087
- </affiliation>
1088
1282
  </person>
1089
1283
  </contributor>
1090
1284
  <contributor>
@@ -1093,12 +1287,6 @@ RSpec.describe Asciidoctor::Standoc do
1093
1287
  <name>
1094
1288
  <completename language='en'>M. Bjorklund</completename>
1095
1289
  </name>
1096
- <affiliation>
1097
- <organization>
1098
- <name>Internet Engineering Task Force</name>
1099
- <abbreviation>IETF</abbreviation>
1100
- </organization>
1101
- </affiliation>
1102
1290
  </person>
1103
1291
  </contributor>
1104
1292
  <contributor>
@@ -1110,7 +1298,8 @@ RSpec.describe Asciidoctor::Standoc do
1110
1298
  </contributor>
1111
1299
  <language>en</language>
1112
1300
  <script>Latn</script>
1113
- <abstract format='text/plain' language='en' script='Latn'>
1301
+ <abstract format='text/html' language='en' script='Latn'>
1302
+ <p id='_'>
1114
1303
  The standardization of network configuration interfaces for use with
1115
1304
  the Network Configuration Protocol (NETCONF) or the RESTCONF protocol
1116
1305
  requires a structured and secure operating environment that promotes
@@ -1118,7 +1307,8 @@ RSpec.describe Asciidoctor::Standoc do
1118
1307
  standard mechanisms to restrict NETCONF or RESTCONF protocol access
1119
1308
  for particular users to a preconfigured subset of all available
1120
1309
  NETCONF or RESTCONF protocol operations and content. This document
1121
- defines such an access control model.This document obsoletes RFC 6536.
1310
+ defines such an access control model.</p>
1311
+ <p id='_'>This document obsoletes RFC 6536.</p>
1122
1312
  </abstract>
1123
1313
  <series type='main'>
1124
1314
  <title format='text/plain' language='en' script='Latn'>STD</title>
@@ -1134,11 +1324,13 @@ RSpec.describe Asciidoctor::Standoc do
1134
1324
  </bibliography>
1135
1325
  </standard-document>
1136
1326
  OUTPUT
1327
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1328
+ .to be_equivalent_to xmlpp(output)
1137
1329
  end
1138
1330
  end
1139
1331
 
1140
1332
  it "processes non-ISO reference in Normative References" do
1141
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1333
+ input = <<~INPUT
1142
1334
  #{ASCIIDOC_BLANK_HDR}
1143
1335
  [bibliography]
1144
1336
  == Normative References
@@ -1146,6 +1338,7 @@ RSpec.describe Asciidoctor::Standoc do
1146
1338
  * [[[iso123,XYZ 123:1066 (all parts)]]] _Standard_
1147
1339
  * [[[iso124,(1)XYZ 123:1066 (all parts)]]] _Standard_
1148
1340
  INPUT
1341
+ output = <<~OUTPUT
1149
1342
  #{BLANK_HDR}
1150
1343
  <sections>
1151
1344
  </sections><bibliography><references id="_" obligation="informative" normative="true">
@@ -1170,10 +1363,12 @@ RSpec.describe Asciidoctor::Standoc do
1170
1363
  </bibliography>
1171
1364
  </standard-document>
1172
1365
  OUTPUT
1366
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1367
+ .to be_equivalent_to xmlpp(output)
1173
1368
  end
1174
1369
 
1175
1370
  it "processes non-ISO reference in Bibliography" do
1176
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1371
+ input = <<~INPUT
1177
1372
  #{ASCIIDOC_BLANK_HDR}
1178
1373
  [bibliography]
1179
1374
  == Bibliography
@@ -1184,6 +1379,7 @@ RSpec.describe Asciidoctor::Standoc do
1184
1379
  * [[[iso126,(A1)]]] _Standard_
1185
1380
  * [[[iso127,(4)XYZ 123:1066 (all parts)]]] _Standard_
1186
1381
  INPUT
1382
+ output = <<~OUTPUT
1187
1383
  #{BLANK_HDR}
1188
1384
  <sections>
1189
1385
  </sections>
@@ -1221,13 +1417,15 @@ RSpec.describe Asciidoctor::Standoc do
1221
1417
  </bibliography>
1222
1418
  </standard-document>
1223
1419
  OUTPUT
1420
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1421
+ .to be_equivalent_to xmlpp(output)
1224
1422
  end
1225
1423
 
1226
1424
  it "process ISO reference without an Internet connection" do
1227
1425
  expect(RelatonIso::IsoBibliography).to receive(:search).with("ISO 123") do
1228
1426
  raise RelatonBib::RequestError.new "getaddrinfo"
1229
1427
  end.at_least :once
1230
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1428
+ input = <<~INPUT
1231
1429
  #{ISOBIB_BLANK_HDR}
1232
1430
  [bibliography]
1233
1431
  == Normative References
@@ -1235,6 +1433,7 @@ RSpec.describe Asciidoctor::Standoc do
1235
1433
  * [[[iso123,ISO 123]]] _Standard_
1236
1434
  * [[[iso124,(1)ISO 123]]] _Standard_
1237
1435
  INPUT
1436
+ output = <<~OUTPUT
1238
1437
  <?xml version="1.0" encoding="UTF-8"?>
1239
1438
  <standard-document xmlns="https://www.metanorma.org/ns/standoc" type="semantic" version="#{Metanorma::Standoc::VERSION}">
1240
1439
  <bibdata type="standard">
@@ -1279,10 +1478,12 @@ RSpec.describe Asciidoctor::Standoc do
1279
1478
  </references></bibliography>
1280
1479
  </standard-document>
1281
1480
  OUTPUT
1481
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1482
+ .to be_equivalent_to xmlpp(output)
1282
1483
  end
1283
1484
 
1284
1485
  it "processes repository reference" do
1285
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1486
+ input = <<~INPUT
1286
1487
  #{ISOBIB_BLANK_HDR}
1287
1488
  == Scope
1288
1489
 
@@ -1297,6 +1498,7 @@ RSpec.describe Asciidoctor::Standoc do
1297
1498
  * [[[iso123,repo:(ab/ISO 123)]]] _Standard_
1298
1499
  * [[[iso124,repo:(ab/ISO 124,id)]]] _Standard_
1299
1500
  INPUT
1501
+ output = <<~OUTPUT
1300
1502
  #{BLANK_HDR}
1301
1503
  <sections>
1302
1504
  <clause id='_' type='scope' inline-header='false' obligation='normative'>
@@ -1350,10 +1552,12 @@ RSpec.describe Asciidoctor::Standoc do
1350
1552
  </bibliography>
1351
1553
  </standard-document>
1352
1554
  OUTPUT
1555
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1556
+ .to be_equivalent_to xmlpp(output)
1353
1557
  end
1354
1558
 
1355
1559
  it "processes hyperlink reference, ingest RXL or XML if available" do
1356
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1560
+ input = <<~INPUT
1357
1561
  #{ISOBIB_BLANK_HDR}
1358
1562
  == Scope
1359
1563
 
@@ -1371,6 +1575,7 @@ RSpec.describe Asciidoctor::Standoc do
1371
1575
  * [[[iso123,path:(spec/assets/iso123,ISO 123)]]] _Standard_
1372
1576
  * [[[iso124,path:(a/b.adoc,ISO 124)]]] _Standard_
1373
1577
  INPUT
1578
+ output = <<~OUTPUT
1374
1579
  #{BLANK_HDR}
1375
1580
  <sections>
1376
1581
  <clause id='_' type="scope" inline-header='false' obligation='normative'>
@@ -1421,7 +1626,7 @@ RSpec.describe Asciidoctor::Standoc do
1421
1626
  amendments) applies.
1422
1627
  </p>
1423
1628
  <bibitem id='iso123' type='standard'>
1424
- <fetched>2020-06-12</fetched>
1629
+ <fetched/>
1425
1630
  <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1426
1631
  <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1427
1632
  <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex – Sampling</title>
@@ -1468,7 +1673,7 @@ RSpec.describe Asciidoctor::Standoc do
1468
1673
  </relation>
1469
1674
  <relation type='instance'>
1470
1675
  <bibitem type='standard'>
1471
- <fetched>2020-06-12</fetched>
1676
+ <fetched/>
1472
1677
  <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1473
1678
  <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1474
1679
  <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex – Sampling</title>
@@ -1540,141 +1745,253 @@ RSpec.describe Asciidoctor::Standoc do
1540
1745
  </bibliography>
1541
1746
  </standard-document>
1542
1747
  OUTPUT
1748
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1749
+ .to be_equivalent_to xmlpp(output)
1543
1750
  end
1544
1751
 
1545
1752
  it "overrides normative status of bibliographies" do
1546
- mock_isobib_get_123_no_docid(1)
1547
- mock_isobib_get_123_no_docid_lbl(1)
1548
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", *OPTIONS)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
1549
- #{ISOBIB_BLANK_HDR}
1550
- [bibliography,normative=false]
1551
- == Normative References
1753
+ # mock_isobib_get_123_no_docid(1)
1754
+ # mock_isobib_get_123_no_docid_lbl(1)
1755
+ VCR.use_cassette "isobib_get_123_1" do
1756
+ input = <<~INPUT
1757
+ #{ISOBIB_BLANK_HDR}
1552
1758
 
1553
- * [[[iso123,ISO 123]]] _Standard_
1759
+ [bibliography,normative=false]
1760
+ == Normative References
1554
1761
 
1555
- [bibliography,normative=true]
1556
- == Bibliography
1762
+ * [[[iso123,ISO 123]]] _Standard_
1557
1763
 
1558
- * [[[iso124,(1)ISO 123]]] _Standard_
1559
- INPUT
1560
- #{BLANK_HDR}
1561
- <sections> </sections>
1562
- <bibliography>
1563
- <references id='_' normative='false' obligation='informative'>
1564
- <title>Bibliography</title>
1565
- <bibitem type='standard' id='iso123'>
1566
- <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1567
- <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1568
- <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
1569
- <date type='published'>
1570
- <on>2001</on>
1571
- </date>
1572
- <contributor>
1573
- <role type='publisher'/>
1574
- <organization>
1575
- <name>International Organization for Standardization</name>
1576
- <abbreviation>ISO</abbreviation>
1577
- <uri>www.iso.org</uri>
1578
- </organization>
1579
- </contributor>
1580
- <edition>3</edition>
1581
- <language>en</language>
1582
- <language>fr</language>
1583
- <script>Latn</script>
1584
- <status>
1585
- <stage>Published</stage>
1586
- </status>
1587
- <copyright>
1588
- <from>2001</from>
1589
- <owner>
1590
- <organization>
1591
- <name>ISO</name>
1592
- <abbreviation/>
1593
- </organization>
1594
- </owner>
1595
- </copyright>
1596
- <relation type='obsoletes'>
1597
- <bibitem type='standard'>
1598
- <formattedref format='text/plain'>ISO 123:1985</formattedref>
1599
- </bibitem>
1600
- </relation>
1601
- <relation type='updates'>
1602
- <bibitem type='standard'>
1603
- <formattedref format='text/plain'>ISO 123:2001</formattedref>
1604
- </bibitem>
1605
- </relation>
1606
- <docidentifier>ISO 123</docidentifier>
1607
- <title>
1608
- <em>Standard</em>
1609
- </title>
1610
- </bibitem>
1611
- </references>
1612
- <references id='_' normative='true' obligation='informative'>
1613
- <title>Normative references</title>
1614
- <p id='_'>
1615
- The following documents are referred to in the text in such a way that
1616
- some or all of their content constitutes requirements of this document.
1617
- For dated references, only the edition cited applies. For undated
1618
- references, the latest edition of the referenced document (including any
1619
- amendments) applies.
1620
- </p>
1621
- <bibitem type='standard' id='iso124'>
1622
- <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1623
- <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1624
- <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
1625
- <date type='published'>
1626
- <on>2001</on>
1627
- </date>
1628
- <contributor>
1629
- <role type='publisher'/>
1630
- <organization>
1631
- <name>International Organization for Standardization</name>
1632
- <abbreviation>ISO</abbreviation>
1633
- <uri>www.iso.org</uri>
1634
- </organization>
1635
- </contributor>
1636
- <edition>3</edition>
1637
- <language>en</language>
1638
- <language>fr</language>
1639
- <script>Latn</script>
1640
- <status>
1641
- <stage>Published</stage>
1642
- </status>
1643
- <copyright>
1644
- <from>2001</from>
1645
- <owner>
1646
- <organization>
1647
- <name>ISO</name>
1648
- <abbreviation/>
1649
- </organization>
1650
- </owner>
1651
- </copyright>
1652
- <relation type='obsoletes'>
1653
- <bibitem type='standard'>
1654
- <formattedref format='text/plain'>ISO 123:1985</formattedref>
1655
- </bibitem>
1656
- </relation>
1657
- <relation type='updates'>
1658
- <bibitem type='standard'>
1659
- <formattedref format='text/plain'>ISO 123:2001</formattedref>
1660
- </bibitem>
1661
- </relation>
1662
- <docidentifier>ISO 123</docidentifier>
1663
- <docidentifier type='metanorma'>[1]</docidentifier>
1664
- <title>
1665
- <em>Standard</em>
1666
- </title>
1667
- </bibitem>
1668
- </references>
1669
- </bibliography>
1670
- </standard-document>
1671
- OUTPUT
1764
+ [bibliography,normative=true]
1765
+ == Bibliography
1766
+
1767
+ * [[[iso124,(1)ISO 123]]] _Standard_
1768
+ INPUT
1769
+ output = <<~OUTPUT
1770
+ #{BLANK_HDR}
1771
+ <sections> </sections>
1772
+ <bibliography>
1773
+ <references id='_' normative='false' obligation='informative'>
1774
+ <title>Bibliography</title>
1775
+ <bibitem id='iso123' type='standard'>
1776
+ <fetched/>
1777
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1778
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1779
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
1780
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1781
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1782
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
1783
+ <docidentifier type='ISO'>ISO 123</docidentifier>
1784
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
1785
+ <docnumber>123</docnumber>
1786
+ <contributor>
1787
+ <role type='publisher'/>
1788
+ <organization>
1789
+ <name>International Organization for Standardization</name>
1790
+ <abbreviation>ISO</abbreviation>
1791
+ <uri>www.iso.org</uri>
1792
+ </organization>
1793
+ </contributor>
1794
+ <edition>3</edition>
1795
+ <language>en</language>
1796
+ <script>Latn</script>
1797
+ <status>
1798
+ <stage>90</stage>
1799
+ <substage>93</substage>
1800
+ </status>
1801
+ <copyright>
1802
+ <from>2001</from>
1803
+ <owner>
1804
+ <organization>
1805
+ <name>ISO</name>
1806
+ </organization>
1807
+ </owner>
1808
+ </copyright>
1809
+ <relation type='obsoletes'>
1810
+ <bibitem type='standard'>
1811
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
1812
+ </bibitem>
1813
+ </relation>
1814
+ <relation type='instance'>
1815
+ <bibitem type='standard'>
1816
+ <fetched/>
1817
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1818
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1819
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
1820
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1821
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1822
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
1823
+ <docidentifier type='ISO'>ISO 123:2001</docidentifier>
1824
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
1825
+ <docnumber>123</docnumber>
1826
+ <date type='published'>
1827
+ <on>2001-05</on>
1828
+ </date>
1829
+ <contributor>
1830
+ <role type='publisher'/>
1831
+ <organization>
1832
+ <name>International Organization for Standardization</name>
1833
+ <abbreviation>ISO</abbreviation>
1834
+ <uri>www.iso.org</uri>
1835
+ </organization>
1836
+ </contributor>
1837
+ <edition>3</edition>
1838
+ <language>en</language>
1839
+ <script>Latn</script>
1840
+ <abstract format='text/plain' language='en' script='Latn'>
1841
+ This International Standard specifies procedures for sampling
1842
+ natural rubber latex concentrate and for sampling synthetic rubber
1843
+ latices and artificial latices. It is also suitable for sampling
1844
+ rubber latex contained in drums, tank cars or tanks. The
1845
+ procedures may also be used for sampling plastics dispersions.
1846
+ </abstract>
1847
+ <status>
1848
+ <stage>90</stage>
1849
+ <substage>93</substage>
1850
+ </status>
1851
+ <copyright>
1852
+ <from>2001</from>
1853
+ <owner>
1854
+ <organization>
1855
+ <name>ISO</name>
1856
+ </organization>
1857
+ </owner>
1858
+ </copyright>
1859
+ <relation type='obsoletes'>
1860
+ <bibitem type='standard'>
1861
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
1862
+ </bibitem>
1863
+ </relation>
1864
+ <place>Geneva</place>
1865
+ </bibitem>
1866
+ </relation>
1867
+ <place>Geneva</place>
1868
+ </bibitem>
1869
+ </references>
1870
+ <references id='_' normative='true' obligation='informative'>
1871
+ <title>Normative references</title>
1872
+ <p id='_'>
1873
+ The following documents are referred to in the text in such a way that
1874
+ some or all of their content constitutes requirements of this document.
1875
+ For dated references, only the edition cited applies. For undated
1876
+ references, the latest edition of the referenced document (including any
1877
+ amendments) applies.
1878
+ </p>
1879
+ <bibitem id='iso124' type='standard'>
1880
+ <fetched/>
1881
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1882
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1883
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
1884
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1885
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1886
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
1887
+ <docidentifier type='ISO'>ISO 123</docidentifier>
1888
+ <docidentifier type='metanorma'>[1]</docidentifier>
1889
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
1890
+ <docnumber>123</docnumber>
1891
+ <contributor>
1892
+ <role type='publisher'/>
1893
+ <organization>
1894
+ <name>International Organization for Standardization</name>
1895
+ <abbreviation>ISO</abbreviation>
1896
+ <uri>www.iso.org</uri>
1897
+ </organization>
1898
+ </contributor>
1899
+ <edition>3</edition>
1900
+ <language>en</language>
1901
+ <script>Latn</script>
1902
+ <status>
1903
+ <stage>90</stage>
1904
+ <substage>93</substage>
1905
+ </status>
1906
+ <copyright>
1907
+ <from>2001</from>
1908
+ <owner>
1909
+ <organization>
1910
+ <name>ISO</name>
1911
+ </organization>
1912
+ </owner>
1913
+ </copyright>
1914
+ <relation type='obsoletes'>
1915
+ <bibitem type='standard'>
1916
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
1917
+ </bibitem>
1918
+ </relation>
1919
+ <relation type='instance'>
1920
+ <bibitem type='standard'>
1921
+ <fetched/>
1922
+ <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1923
+ <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1924
+ <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
1925
+ <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1926
+ <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1927
+ <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
1928
+ <docidentifier type='ISO'>ISO 123:2001</docidentifier>
1929
+ <docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3:en</docidentifier>
1930
+ <docnumber>123</docnumber>
1931
+ <date type='published'>
1932
+ <on>2001-05</on>
1933
+ </date>
1934
+ <contributor>
1935
+ <role type='publisher'/>
1936
+ <organization>
1937
+ <name>International Organization for Standardization</name>
1938
+ <abbreviation>ISO</abbreviation>
1939
+ <uri>www.iso.org</uri>
1940
+ </organization>
1941
+ </contributor>
1942
+ <edition>3</edition>
1943
+ <language>en</language>
1944
+ <script>Latn</script>
1945
+ <abstract format='text/plain' language='en' script='Latn'>
1946
+ This International Standard specifies procedures for sampling
1947
+ natural rubber latex concentrate and for sampling synthetic rubber
1948
+ latices and artificial latices. It is also suitable for sampling
1949
+ rubber latex contained in drums, tank cars or tanks. The
1950
+ procedures may also be used for sampling plastics dispersions.
1951
+ </abstract>
1952
+ <status>
1953
+ <stage>90</stage>
1954
+ <substage>93</substage>
1955
+ </status>
1956
+ <copyright>
1957
+ <from>2001</from>
1958
+ <owner>
1959
+ <organization>
1960
+ <name>ISO</name>
1961
+ </organization>
1962
+ </owner>
1963
+ </copyright>
1964
+ <relation type='obsoletes'>
1965
+ <bibitem type='standard'>
1966
+ <formattedref format='text/plain'>ISO 123:1985</formattedref>
1967
+ </bibitem>
1968
+ </relation>
1969
+ <place>Geneva</place>
1970
+ </bibitem>
1971
+ </relation>
1972
+ <place>Geneva</place>
1973
+ </bibitem>
1974
+ </references>
1975
+ </bibliography>
1976
+ </standard-document>
1977
+ OUTPUT
1978
+ expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
1979
+ .to be_equivalent_to xmlpp(output)
1980
+ end
1672
1981
  end
1673
1982
 
1674
1983
  private
1675
1984
 
1676
1985
  def mock_isobib_get_123
1677
- expect(RelatonIso::IsoBibliography).to receive(:get).with("ISO 123", nil, {}) do
1986
+ expect(RelatonIso::IsoBibliography).to receive(:get)
1987
+ .with("ISO 123", nil, { code: "ISO 123",
1988
+ lang: "en",
1989
+ match: anything,
1990
+ process: 1,
1991
+ ord: anything,
1992
+ title: "<em>Standard</em>",
1993
+ usrlbl: nil,
1994
+ year: nil }) do
1678
1995
  IsoBibItem::XMLParser.from_xml(<<~"OUTPUT")
1679
1996
  <bibitem type=\"standard\" id=\"ISO123\">\n <title format=\"text/plain\" language=\"en\" script=\"Latn\">Rubber latex -- Sampling</title>\n <title format=\"text/plain\" language=\"fr\" script=\"Latn\">Latex de caoutchouc -- ?chantillonnage</title>\n <uri type=\"src\">https://www.iso.org/standard/23281.html</uri>\n <uri type=\"obp\">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>\n <uri type=\"rss\">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>\n <docidentifier>ISO 123</docidentifier>\n <date type=\"published\">\n <on>2001</on>\n </date>\n <contributor>\n <role type=\"publisher\"/>\n <organization>\n <name>International Organization for Standardization</name>\n <abbreviation>ISO</abbreviation>\n <uri>www.iso.org</uri>\n </organization>\n </contributor>\n <edition>3</edition>\n <language>en</language>\n <language>fr</language>\n <script>Latn</script>\n <status>Published</status>\n <copyright>\n <from>2001</from>\n <owner>\n <organization>\n <name>ISO</name>\n <abbreviation></abbreviation>\n </organization>\n </owner>\n </copyright>\n <relation type=\"obsoletes\">\n <bibitem type="standard">\n <formattedref format="text/plain">ISO 123:1985</formattedref>\n </bibitem>\n </relation>\n <relation type=\"updates\">\n <bibitem type="standard">\n <formattedref format="text/plain">ISO 123:2001</formattedref>\n </bibitem>\n </relation>\n</bibitem>
1680
1997
  OUTPUT
@@ -1682,7 +1999,15 @@ RSpec.describe Asciidoctor::Standoc do
1682
1999
  end
1683
2000
 
1684
2001
  def mock_isobib_get_123_no_docid(n)
1685
- expect(RelatonIso::IsoBibliography).to receive(:get).with("ISO 123", nil, { lang: "en", title: "<em>Standard</em>", usrlbl: nil }) do
2002
+ expect(RelatonIso::IsoBibliography).to receive(:get)
2003
+ .with("ISO 123", nil, { code: "ISO 123",
2004
+ lang: "en",
2005
+ match: anything,
2006
+ process: 1,
2007
+ ord: anything,
2008
+ title: "<em>Standard</em>",
2009
+ usrlbl: nil,
2010
+ year: nil }) do
1686
2011
  RelatonBib::XMLParser.from_xml(<<~"OUTPUT")
1687
2012
  <bibitem type=\"standard\" id=\"ISO123\">\n <uri type=\"src\">https://www.iso.org/standard/23281.html</uri>\n <uri type=\"obp\">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>\n <uri type=\"rss\">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>\n <date type=\"published\">\n <on>2001</on>\n </date>\n <contributor>\n <role type=\"publisher\"/>\n <organization>\n <name>International Organization for Standardization</name>\n <abbreviation>ISO</abbreviation>\n <uri>www.iso.org</uri>\n </organization>\n </contributor>\n <edition>3</edition>\n <language>en</language>\n <language>fr</language>\n <script>Latn</script>\n <status><stage>Published</stage></status>\n <copyright>\n <from>2001</from>\n <owner>\n <organization>\n <name>ISO</name>\n <abbreviation></abbreviation>\n </organization>\n </owner>\n </copyright>\n <relation type=\"obsoletes\">\n <bibitem type="standard">\n <formattedref format="text/plain">ISO 123:1985</formattedref>\n </bibitem>\n </relation>\n <relation type=\"updates\">\n <bibitem type="standard">\n <formattedref format="text/plain">ISO 123:2001</formattedref>\n </bibitem>\n </relation>\n<ext></fred></ext></bibitem>
1688
2013
  OUTPUT
@@ -1690,7 +2015,15 @@ RSpec.describe Asciidoctor::Standoc do
1690
2015
  end
1691
2016
 
1692
2017
  def mock_isobib_get_123_no_docid_lbl(n)
1693
- expect(RelatonIso::IsoBibliography).to receive(:get).with("ISO 123", nil, { lang: "en", title: "<em>Standard</em>", usrlbl: "(1)" }) do
2018
+ expect(RelatonIso::IsoBibliography).to receive(:get)
2019
+ .with("ISO 123", nil, { code: "ISO 123",
2020
+ lang: "en",
2021
+ match: anything,
2022
+ process: 1,
2023
+ ord: anything,
2024
+ title: "<em>Standard</em>",
2025
+ usrlbl: "(1)",
2026
+ year: nil }) do
1694
2027
  RelatonBib::XMLParser.from_xml(<<~"OUTPUT")
1695
2028
  <bibitem type=\"standard\" id=\"ISO123\">\n <uri type=\"src\">https://www.iso.org/standard/23281.html</uri>\n <uri type=\"obp\">https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>\n <uri type=\"rss\">https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>\n <date type=\"published\">\n <on>2001</on>\n </date>\n <contributor>\n <role type=\"publisher\"/>\n <organization>\n <name>International Organization for Standardization</name>\n <abbreviation>ISO</abbreviation>\n <uri>www.iso.org</uri>\n </organization>\n </contributor>\n <edition>3</edition>\n <language>en</language>\n <language>fr</language>\n <script>Latn</script>\n <status><stage>Published</stage></status>\n <copyright>\n <from>2001</from>\n <owner>\n <organization>\n <name>ISO</name>\n <abbreviation></abbreviation>\n </organization>\n </owner>\n </copyright>\n <relation type=\"obsoletes\">\n <bibitem type="standard">\n <formattedref format="text/plain">ISO 123:1985</formattedref>\n </bibitem>\n </relation>\n <relation type=\"updates\">\n <bibitem type="standard">\n <formattedref format="text/plain">ISO 123:2001</formattedref>\n </bibitem>\n </relation>\n<ext></fred></ext></bibitem>
1696
2029
  OUTPUT
@@ -1698,7 +2031,9 @@ RSpec.describe Asciidoctor::Standoc do
1698
2031
  end
1699
2032
 
1700
2033
  def mock_isobib_get_124
1701
- expect(RelatonIso::IsoBibliography).to receive(:get).with("ISO 124", "2014", {}) do
2034
+ expect(RelatonIso::IsoBibliography).to receive(:get)
2035
+ .with("ISO 124",
2036
+ "2014", anything) do
1702
2037
  IsoBibItem::XMLParser.from_xml(<<~"OUTPUT")
1703
2038
  <bibitem type="standard" id="iso124">
1704
2039
  <title format="text/plain" language="en" script="Latn">Latex, rubber -- Determination of total solids content</title>
@@ -1748,7 +2083,9 @@ RSpec.describe Asciidoctor::Standoc do
1748
2083
  end
1749
2084
 
1750
2085
  def mock_isobib_get_iec12382
1751
- expect(RelatonIso::IsoBibliography).to receive(:get).with("ISO/IEC TR 12382", "1992", {}) do
2086
+ expect(RelatonIso::IsoBibliography).to receive(:get).with(
2087
+ "ISO/IEC TR 12382", "1992", anything
2088
+ ) do
1752
2089
  IsoBibItem::XMLParser.from_xml(<<~"OUTPUT")
1753
2090
  <bibitem type="standard" id="iso123">
1754
2091
  <title format="text/plain" language="en" script="Latn">Permuted index of the vocabulary of information technology</title>
@@ -1810,7 +2147,8 @@ RSpec.describe Asciidoctor::Standoc do
1810
2147
  end
1811
2148
 
1812
2149
  def mock_rfcbib_get_rfc8341
1813
- expect(IETFBib::RfcBibliography).to receive(:get).with("RFC 8341", nil, {}) do
2150
+ expect(IETFBib::RfcBibliography).to receive(:get).with("RFC 8341", nil,
2151
+ anything) do
1814
2152
  IsoBibItem::XMLParser.from_xml(<<~"OUTPUT")
1815
2153
  <bibitem id="RFC8341">
1816
2154
  <title format="text/plain" language="en" script="Latn">Network Configuration Access Control Model</title>