metanorma-iso 2.1.2 → 2.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/html2doc/lists.rb +7 -4
- data/lib/isodoc/iso/html/isodoc-dis.css +4 -15
- data/lib/isodoc/iso/html/isodoc-dis.scss +4 -17
- data/lib/isodoc/iso/html/isodoc.css +4 -11
- data/lib/isodoc/iso/html/isodoc.scss +5 -15
- data/lib/isodoc/iso/i18n-en.yaml +1 -1
- data/lib/isodoc/iso/iso.amendment.xsl +429 -121
- data/lib/isodoc/iso/iso.international-standard.xsl +429 -121
- data/lib/isodoc/iso/metadata.rb +1 -1
- data/lib/isodoc/iso/presentation_xml_convert.rb +5 -1
- data/lib/isodoc/iso/word_cleanup.rb +40 -6
- data/lib/isodoc/iso/word_dis_cleanup.rb +10 -14
- data/lib/metanorma/iso/base.rb +0 -6
- data/lib/metanorma/iso/biblio.rng +102 -5
- data/lib/metanorma/iso/cleanup.rb +33 -20
- data/lib/metanorma/iso/front.rb +13 -6
- data/lib/metanorma/iso/isodoc.rng +33 -0
- data/lib/metanorma/iso/isostandard.rng +3 -1
- data/lib/metanorma/iso/validate_section.rb +0 -12
- data/lib/metanorma/iso/version.rb +1 -1
- data/spec/isodoc/blocks_spec.rb +3 -3
- data/spec/isodoc/metadata_spec.rb +1 -2
- data/spec/isodoc/postproc_spec.rb +2 -62
- data/spec/isodoc/section_spec.rb +2 -8
- data/spec/isodoc/terms_spec.rb +62 -0
- data/spec/isodoc/word_dis_spec.rb +185 -3
- data/spec/metanorma/amd_spec.rb +4 -40
- data/spec/metanorma/base_spec.rb +61 -103
- data/spec/metanorma/blocks_spec.rb +0 -33
- data/spec/metanorma/cleanup_spec.rb +201 -201
- data/spec/metanorma/refs_spec.rb +5 -3
- data/spec/metanorma/section_spec.rb +6 -6
- data/spec/metanorma/validate_spec.rb +8 -19
- data/spec/spec_helper.rb +1 -7
- data/spec/vcr_cassettes/withdrawn_iso.yml +28 -28
- metadata +3 -4
- data/lib/metanorma/iso/macros.rb +0 -29
data/spec/metanorma/base_spec.rb
CHANGED
@@ -193,13 +193,16 @@ RSpec.describe Metanorma::ISO do
|
|
193
193
|
:docsubstage:
|
194
194
|
:technical-committee: TC
|
195
195
|
:technical-committee-number: 1
|
196
|
-
:technical-committee-type: A
|
197
196
|
:subcommittee: SC
|
198
197
|
:subcommittee-number: 2
|
199
|
-
:subcommittee-type: B
|
200
198
|
:workgroup: WG
|
201
199
|
:workgroup-number: 3
|
202
|
-
:
|
200
|
+
:approval-technical-committee: TC
|
201
|
+
:approval-technical-committee-number: 1
|
202
|
+
:approval-subcommittee: SC
|
203
|
+
:approval-subcommittee-number: 2
|
204
|
+
:approval-workgroup: WG
|
205
|
+
:approval-workgroup-number: 3
|
203
206
|
INPUT
|
204
207
|
expect(xmlpp(output.sub(%r{<boilerplate>.*</boilerplate>}m, "")))
|
205
208
|
.to be_equivalent_to xmlpp(<<~"OUTPUT")
|
@@ -317,15 +320,15 @@ RSpec.describe Metanorma::ISO do
|
|
317
320
|
<agency>IEC</agency>
|
318
321
|
<agency>IETF</agency>
|
319
322
|
<agency>ISO</agency>
|
320
|
-
<technical-committee number='1' type='
|
321
|
-
<subcommittee number='2' type='
|
322
|
-
<workgroup number='3' type='
|
323
|
+
<technical-committee number='1' type='TC'>TC</technical-committee>
|
324
|
+
<subcommittee number='2' type='SC'>SC</subcommittee>
|
325
|
+
<workgroup number='3' type='WG'>WG</workgroup>
|
323
326
|
</editorialgroup>
|
324
327
|
<approvalgroup>
|
325
328
|
<agency>ISO</agency>
|
326
|
-
<technical-committee number='1' type='
|
327
|
-
<subcommittee number='2' type='
|
328
|
-
<workgroup number='3' type='
|
329
|
+
<technical-committee number='1' type='TC'>TC</technical-committee>
|
330
|
+
<subcommittee number='2' type='SC'>SC</subcommittee>
|
331
|
+
<workgroup number='3' type='WG'>WG</workgroup>
|
329
332
|
</approvalgroup>
|
330
333
|
<structuredidentifier>
|
331
334
|
<project-number part="1" subpart="1">IEC/IETF/ISO 1000</project-number>
|
@@ -393,18 +396,12 @@ RSpec.describe Metanorma::ISO do
|
|
393
396
|
</copyright>
|
394
397
|
<ext>
|
395
398
|
<doctype>technical-specification</doctype>
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
<approvalgroup>
|
403
|
-
<agency>ISO</agency>
|
404
|
-
<technical-committee/>
|
405
|
-
<subcommittee/>
|
406
|
-
<workgroup/>
|
407
|
-
</approvalgroup>
|
399
|
+
<editorialgroup>
|
400
|
+
<agency>ISO</agency>
|
401
|
+
</editorialgroup>
|
402
|
+
<approvalgroup>
|
403
|
+
<agency>ISO</agency>
|
404
|
+
</approvalgroup>
|
408
405
|
<structuredidentifier>
|
409
406
|
<project-number part='1' subpart='1'>ISO 1000</project-number>
|
410
407
|
</structuredidentifier>
|
@@ -509,18 +506,12 @@ RSpec.describe Metanorma::ISO do
|
|
509
506
|
<ext>
|
510
507
|
<doctype>standard</doctype>
|
511
508
|
<horizontal>true</horizontal>
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
<approvalgroup>
|
519
|
-
<agency>ISO</agency>
|
520
|
-
<technical-committee/>
|
521
|
-
<subcommittee/>
|
522
|
-
<workgroup/>
|
523
|
-
</approvalgroup>
|
509
|
+
<editorialgroup>
|
510
|
+
<agency>ISO</agency>
|
511
|
+
</editorialgroup>
|
512
|
+
<approvalgroup>
|
513
|
+
<agency>ISO</agency>
|
514
|
+
</approvalgroup>
|
524
515
|
<structuredidentifier>
|
525
516
|
<project-number part='1'>ISO 1000</project-number>
|
526
517
|
</structuredidentifier>
|
@@ -623,18 +614,12 @@ RSpec.describe Metanorma::ISO do
|
|
623
614
|
</copyright>
|
624
615
|
<ext>
|
625
616
|
<doctype>this-is-a-doctype</doctype>
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
<approvalgroup>
|
633
|
-
<agency>ISO</agency>
|
634
|
-
<technical-committee/>
|
635
|
-
<subcommittee/>
|
636
|
-
<workgroup/>
|
637
|
-
</approvalgroup>
|
617
|
+
<editorialgroup>
|
618
|
+
<agency>SD</agency>
|
619
|
+
</editorialgroup>
|
620
|
+
<approvalgroup>
|
621
|
+
<agency>ISO</agency>
|
622
|
+
</approvalgroup>
|
638
623
|
<structuredidentifier>
|
639
624
|
<project-number part="1" subpart="1">SD 1000</project-number>
|
640
625
|
</structuredidentifier>
|
@@ -701,18 +686,12 @@ RSpec.describe Metanorma::ISO do
|
|
701
686
|
</copyright>
|
702
687
|
<ext>
|
703
688
|
<doctype>international-standard</doctype>
|
704
|
-
|
705
|
-
|
706
|
-
|
707
|
-
|
708
|
-
|
709
|
-
|
710
|
-
<approvalgroup>
|
711
|
-
<agency>ISO</agency>
|
712
|
-
<technical-committee/>
|
713
|
-
<subcommittee/>
|
714
|
-
<workgroup/>
|
715
|
-
</approvalgroup>
|
689
|
+
<editorialgroup>
|
690
|
+
<agency>ISO</agency>
|
691
|
+
</editorialgroup>
|
692
|
+
<approvalgroup>
|
693
|
+
<agency>ISO</agency>
|
694
|
+
</approvalgroup>
|
716
695
|
<structuredidentifier>
|
717
696
|
<project-number>ISO 1000</project-number>
|
718
697
|
</structuredidentifier>
|
@@ -777,17 +756,11 @@ RSpec.describe Metanorma::ISO do
|
|
777
756
|
</copyright>
|
778
757
|
<ext>
|
779
758
|
<doctype>standard</doctype>
|
780
|
-
|
759
|
+
<editorialgroup>
|
781
760
|
<agency>ISO</agency>
|
782
|
-
<technical-committee/>
|
783
|
-
<subcommittee/>
|
784
|
-
<workgroup/>
|
785
761
|
</editorialgroup>
|
786
762
|
<approvalgroup>
|
787
763
|
<agency>ISO</agency>
|
788
|
-
<technical-committee/>
|
789
|
-
<subcommittee/>
|
790
|
-
<workgroup/>
|
791
764
|
</approvalgroup>
|
792
765
|
<structuredidentifier>
|
793
766
|
<project-number>ISO 1000</project-number>
|
@@ -853,18 +826,12 @@ RSpec.describe Metanorma::ISO do
|
|
853
826
|
</copyright>
|
854
827
|
<ext>
|
855
828
|
<doctype>standard</doctype>
|
856
|
-
|
857
|
-
|
858
|
-
|
859
|
-
|
860
|
-
|
861
|
-
|
862
|
-
<approvalgroup>
|
863
|
-
<agency>ISO</agency>
|
864
|
-
<technical-committee/>
|
865
|
-
<subcommittee/>
|
866
|
-
<workgroup/>
|
867
|
-
</approvalgroup>
|
829
|
+
<editorialgroup>
|
830
|
+
<agency>ISO</agency>
|
831
|
+
</editorialgroup>
|
832
|
+
<approvalgroup>
|
833
|
+
<agency>ISO</agency>
|
834
|
+
</approvalgroup>
|
868
835
|
<structuredidentifier>
|
869
836
|
<project-number>ISO 1000</project-number>
|
870
837
|
</structuredidentifier>
|
@@ -928,18 +895,12 @@ RSpec.describe Metanorma::ISO do
|
|
928
895
|
</copyright>
|
929
896
|
<ext>
|
930
897
|
<doctype>directive</doctype>
|
931
|
-
|
932
|
-
|
933
|
-
|
934
|
-
|
935
|
-
|
936
|
-
|
937
|
-
<approvalgroup>
|
938
|
-
<agency>ISO</agency>
|
939
|
-
<technical-committee/>
|
940
|
-
<subcommittee/>
|
941
|
-
<workgroup/>
|
942
|
-
</approvalgroup>
|
898
|
+
<editorialgroup>
|
899
|
+
<agency>ISO</agency>
|
900
|
+
</editorialgroup>
|
901
|
+
<approvalgroup>
|
902
|
+
<agency>ISO</agency>
|
903
|
+
</approvalgroup>
|
943
904
|
<structuredidentifier>
|
944
905
|
<project-number>ISO 1000</project-number>
|
945
906
|
</structuredidentifier>
|
@@ -1054,7 +1015,7 @@ RSpec.describe Metanorma::ISO do
|
|
1054
1015
|
<uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
|
1055
1016
|
<uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
|
1056
1017
|
<docidentifier type='ISO' primary="true">ISO 123:2001</docidentifier>
|
1057
|
-
<docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3
|
1018
|
+
<docidentifier type='URN'>urn:iso:std:iso:123:stage-90.93:ed-3</docidentifier>
|
1058
1019
|
<docnumber>123</docnumber>
|
1059
1020
|
<date type='published'><on>2001-05</on></date>
|
1060
1021
|
<contributor>
|
@@ -1101,6 +1062,7 @@ RSpec.describe Metanorma::ISO do
|
|
1101
1062
|
<relation type='obsoletes'>
|
1102
1063
|
<bibitem type='standard'>
|
1103
1064
|
<formattedref format='text/plain'>ISO 123:1985</formattedref>
|
1065
|
+
<docidentifier type='ISO' primary='true'>ISO 123:1985</docidentifier>
|
1104
1066
|
</bibitem>
|
1105
1067
|
</relation>
|
1106
1068
|
<place>Geneva</place>
|
@@ -1127,7 +1089,7 @@ RSpec.describe Metanorma::ISO do
|
|
1127
1089
|
<uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:72849:en</uri>
|
1128
1090
|
<uri type='rss'>https://www.iso.org/contents/data/standard/07/28/72849.detail.rss</uri>
|
1129
1091
|
<docidentifier type='ISO' primary="true">ISO 125</docidentifier>
|
1130
|
-
<docidentifier type='URN'>urn:iso:std:iso:125:stage-60.60:ed-7
|
1092
|
+
<docidentifier type='URN'>urn:iso:std:iso:125:stage-60.60:ed-7</docidentifier>
|
1131
1093
|
<docnumber>125</docnumber>
|
1132
1094
|
<contributor>
|
1133
1095
|
<role type='publisher'/>
|
@@ -1156,6 +1118,7 @@ RSpec.describe Metanorma::ISO do
|
|
1156
1118
|
<relation type='obsoletes'>
|
1157
1119
|
<bibitem type='standard'>
|
1158
1120
|
<formattedref format='text/plain'>ISO 125:2011</formattedref>
|
1121
|
+
<docidentifier type='ISO' primary='true'>ISO 125:2011</docidentifier>
|
1159
1122
|
</bibitem>
|
1160
1123
|
</relation>
|
1161
1124
|
<relation type='instance'>
|
@@ -1178,7 +1141,7 @@ RSpec.describe Metanorma::ISO do
|
|
1178
1141
|
<uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:72849:en</uri>
|
1179
1142
|
<uri type='rss'>https://www.iso.org/contents/data/standard/07/28/72849.detail.rss</uri>
|
1180
1143
|
<docidentifier type='ISO' primary="true">ISO 125:2020</docidentifier>
|
1181
|
-
<docidentifier type='URN'>urn:iso:std:iso:125:stage-60.60:ed-7
|
1144
|
+
<docidentifier type='URN'>urn:iso:std:iso:125:stage-60.60:ed-7</docidentifier>
|
1182
1145
|
<docnumber>125</docnumber>
|
1183
1146
|
<date type='published'>
|
1184
1147
|
<on>2020-02</on>
|
@@ -1231,6 +1194,7 @@ RSpec.describe Metanorma::ISO do
|
|
1231
1194
|
<relation type='obsoletes'>
|
1232
1195
|
<bibitem type='standard'>
|
1233
1196
|
<formattedref format='text/plain'>ISO 125:2011</formattedref>
|
1197
|
+
<docidentifier type='ISO' primary='true'>ISO 125:2011</docidentifier>
|
1234
1198
|
</bibitem>
|
1235
1199
|
</relation>
|
1236
1200
|
<place>Geneva</place>
|
@@ -1311,18 +1275,12 @@ RSpec.describe Metanorma::ISO do
|
|
1311
1275
|
</relation>
|
1312
1276
|
<ext>
|
1313
1277
|
<doctype>standard</doctype>
|
1314
|
-
|
1315
|
-
|
1316
|
-
|
1317
|
-
|
1318
|
-
|
1319
|
-
|
1320
|
-
<approvalgroup>
|
1321
|
-
<agency>ISO</agency>
|
1322
|
-
<technical-committee/>
|
1323
|
-
<subcommittee/>
|
1324
|
-
<workgroup/>
|
1325
|
-
</approvalgroup>
|
1278
|
+
<editorialgroup>
|
1279
|
+
<agency>ISO</agency>
|
1280
|
+
</editorialgroup>
|
1281
|
+
<approvalgroup>
|
1282
|
+
<agency>ISO</agency>
|
1283
|
+
</approvalgroup>
|
1326
1284
|
<stagename>International standard</stagename>
|
1327
1285
|
</ext>
|
1328
1286
|
</bibdata>
|
@@ -621,37 +621,4 @@ RSpec.describe Metanorma::ISO do
|
|
621
621
|
expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
|
622
622
|
.to be_equivalent_to xmlpp(output)
|
623
623
|
end
|
624
|
-
|
625
|
-
it "processes the macro for editorial notes" do
|
626
|
-
input = <<~INPUT
|
627
|
-
#{ASCIIDOC_BLANK_HDR}
|
628
|
-
EDITOR: Note1
|
629
|
-
|
630
|
-
[EDITOR]
|
631
|
-
====
|
632
|
-
Note2
|
633
|
-
====
|
634
|
-
|
635
|
-
[EDITOR]
|
636
|
-
Note3
|
637
|
-
INPUT
|
638
|
-
output = <<~OUTPUT
|
639
|
-
#{BLANK_HDR}
|
640
|
-
<sections>
|
641
|
-
<admonition id='_' type='editorial'>
|
642
|
-
<p id='_'>Note1</p>
|
643
|
-
</admonition>
|
644
|
-
<admonition id='_' type='editorial'>
|
645
|
-
<p id='_'>Note2</p>
|
646
|
-
</admonition>
|
647
|
-
<admonition id='_' type='editorial'>
|
648
|
-
<p id='_'>Note3</p>
|
649
|
-
</admonition>
|
650
|
-
</sections>
|
651
|
-
</iso-standard>
|
652
|
-
OUTPUT
|
653
|
-
expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
|
654
|
-
.to be_equivalent_to xmlpp(output)
|
655
|
-
end
|
656
|
-
|
657
624
|
end
|