metanorma-iec 1.4.5 → 2.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rake.yml +4 -32
- data/.gitignore +14 -0
- data/Gemfile +4 -0
- data/lib/isodoc/iec/base_convert.rb +3 -2
- data/lib/isodoc/iec/html/htmlstyle.css +23 -17
- data/lib/isodoc/iec/html/htmlstyle.scss +9 -3
- data/lib/isodoc/iec/html/isodoc.css +1 -2
- data/lib/isodoc/iec/html/isodoc.scss +0 -1
- data/lib/isodoc/iec/html_convert.rb +2 -1
- data/lib/isodoc/iec/i18n-fr.yaml +1 -1
- data/lib/isodoc/iec/iec.international-standard.xsl +2198 -1850
- data/lib/isodoc/iec/word_convert.rb +2 -0
- data/lib/isodoc/iec/xref.rb +9 -8
- data/lib/{asciidoctor → metanorma}/iec/basicdoc.rng +5 -3
- data/lib/{asciidoctor → metanorma}/iec/biblio.rng +7 -5
- data/lib/{asciidoctor → metanorma}/iec/converter.rb +22 -8
- data/lib/{asciidoctor → metanorma}/iec/front.rb +1 -1
- data/lib/{asciidoctor → metanorma}/iec/iec.rng +0 -0
- data/lib/{asciidoctor → metanorma}/iec/iec_intro_en.xml +0 -0
- data/lib/{asciidoctor → metanorma}/iec/iec_intro_fr.xml +0 -0
- data/lib/{asciidoctor → metanorma}/iec/isodoc.rng +98 -1
- data/lib/{asciidoctor → metanorma}/iec/isostandard.rng +0 -0
- data/lib/{asciidoctor → metanorma}/iec/reqt.rng +0 -0
- data/lib/metanorma/iec/version.rb +1 -1
- data/lib/metanorma-iec.rb +1 -1
- data/metanorma-iec.gemspec +1 -1
- data/spec/isodoc/i18n_spec.rb +2 -2
- data/spec/isodoc/iev_spec.rb +6 -5
- data/spec/isodoc/ref_spec.rb +359 -353
- data/spec/{asciidoctor → metanorma}/base_spec.rb +1 -1
- data/spec/{asciidoctor → metanorma}/blocks_spec.rb +1 -1
- data/spec/{asciidoctor → metanorma}/cleanup_spec.rb +1 -1
- data/spec/{asciidoctor → metanorma}/iev_spec.rb +10 -2
- data/spec/{asciidoctor → metanorma}/inline_spec.rb +1 -1
- data/spec/{asciidoctor → metanorma}/lists_spec.rb +1 -1
- data/spec/{asciidoctor → metanorma}/section_spec.rb +1 -1
- data/spec/{asciidoctor → metanorma}/validate_spec.rb +1 -1
- data/spec/spec_helper.rb +2 -2
- metadata +22 -22
@@ -1,7 +1,7 @@
|
|
1
1
|
require "spec_helper"
|
2
2
|
require "fileutils"
|
3
3
|
|
4
|
-
RSpec.describe
|
4
|
+
RSpec.describe Metanorma::Iec do
|
5
5
|
before(:all) do
|
6
6
|
@boilerplate = boilerplate(Nokogiri::XML("#{BLANK_HDR}</iec-standard>"))
|
7
7
|
end
|
@@ -75,7 +75,13 @@ RSpec.describe Asciidoctor::Iec do
|
|
75
75
|
<bibliography>
|
76
76
|
<references id='_' obligation='informative' normative="true">
|
77
77
|
<title>Normative references</title>
|
78
|
-
<p id='_'>
|
78
|
+
<p id='_'>
|
79
|
+
The following documents are referred to in the text in such a way that
|
80
|
+
some or all of their content constitutes requirements of this document.
|
81
|
+
For dated references, only the edition cited applies. For undated
|
82
|
+
references, the latest edition of the referenced document (including any
|
83
|
+
amendments) applies.
|
84
|
+
</p>
|
79
85
|
<bibitem id='A'>
|
80
86
|
<formattedref format='application/x-isodoc+xml'>
|
81
87
|
<em>TITLE</em>
|
@@ -167,6 +173,8 @@ RSpec.describe Asciidoctor::Iec do
|
|
167
173
|
</iec-standard>
|
168
174
|
|
169
175
|
OUTPUT
|
176
|
+
expect(xmlpp(strip_guid(Asciidoctor.convert(input, *OPTIONS))))
|
177
|
+
.to be_equivalent_to xmlpp(output)
|
170
178
|
end
|
171
179
|
|
172
180
|
it "uses IEV introduction title" do
|
data/spec/spec_helper.rb
CHANGED
@@ -118,10 +118,10 @@ BOILERPLATE
|
|
118
118
|
|
119
119
|
def boilerplate(xmldoc)
|
120
120
|
file = File.read(
|
121
|
-
File.join(File.dirname(__FILE__), "..", "lib", "
|
121
|
+
File.join(File.dirname(__FILE__), "..", "lib", "metanorma", "iec",
|
122
122
|
"iec_intro_en.xml"), encoding: "utf-8"
|
123
123
|
)
|
124
|
-
conv =
|
124
|
+
conv = Metanorma::Iec::Converter.new(nil, backend: :iec,
|
125
125
|
header_footer: true)
|
126
126
|
conv.init(Asciidoctor::Document.new([]))
|
127
127
|
ret = Nokogiri::XML(
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-iec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-02-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-iso
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: 2.0.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
26
|
+
version: 2.0.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: ruby-jing
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -212,16 +212,6 @@ files:
|
|
212
212
|
- README.adoc
|
213
213
|
- Rakefile
|
214
214
|
- bin/rspec
|
215
|
-
- lib/asciidoctor/iec/basicdoc.rng
|
216
|
-
- lib/asciidoctor/iec/biblio.rng
|
217
|
-
- lib/asciidoctor/iec/converter.rb
|
218
|
-
- lib/asciidoctor/iec/front.rb
|
219
|
-
- lib/asciidoctor/iec/iec.rng
|
220
|
-
- lib/asciidoctor/iec/iec_intro_en.xml
|
221
|
-
- lib/asciidoctor/iec/iec_intro_fr.xml
|
222
|
-
- lib/asciidoctor/iec/isodoc.rng
|
223
|
-
- lib/asciidoctor/iec/isostandard.rng
|
224
|
-
- lib/asciidoctor/iec/reqt.rng
|
225
215
|
- lib/isodoc/iec/base_convert.rb
|
226
216
|
- lib/isodoc/iec/html/header.html
|
227
217
|
- lib/isodoc/iec/html/html_iec_intro.html
|
@@ -249,17 +239,19 @@ files:
|
|
249
239
|
- lib/isodoc/iec/xref.rb
|
250
240
|
- lib/metanorma-iec.rb
|
251
241
|
- lib/metanorma/iec.rb
|
242
|
+
- lib/metanorma/iec/basicdoc.rng
|
243
|
+
- lib/metanorma/iec/biblio.rng
|
244
|
+
- lib/metanorma/iec/converter.rb
|
245
|
+
- lib/metanorma/iec/front.rb
|
246
|
+
- lib/metanorma/iec/iec.rng
|
247
|
+
- lib/metanorma/iec/iec_intro_en.xml
|
248
|
+
- lib/metanorma/iec/iec_intro_fr.xml
|
249
|
+
- lib/metanorma/iec/isodoc.rng
|
250
|
+
- lib/metanorma/iec/isostandard.rng
|
252
251
|
- lib/metanorma/iec/processor.rb
|
252
|
+
- lib/metanorma/iec/reqt.rng
|
253
253
|
- lib/metanorma/iec/version.rb
|
254
254
|
- metanorma-iec.gemspec
|
255
|
-
- spec/asciidoctor/base_spec.rb
|
256
|
-
- spec/asciidoctor/blocks_spec.rb
|
257
|
-
- spec/asciidoctor/cleanup_spec.rb
|
258
|
-
- spec/asciidoctor/iev_spec.rb
|
259
|
-
- spec/asciidoctor/inline_spec.rb
|
260
|
-
- spec/asciidoctor/lists_spec.rb
|
261
|
-
- spec/asciidoctor/section_spec.rb
|
262
|
-
- spec/asciidoctor/validate_spec.rb
|
263
255
|
- spec/assets/header.html
|
264
256
|
- spec/assets/html.css
|
265
257
|
- spec/assets/iso.xml
|
@@ -277,7 +269,15 @@ files:
|
|
277
269
|
- spec/isodoc/ref_spec.rb
|
278
270
|
- spec/isodoc/section_spec.rb
|
279
271
|
- spec/isodoc/terms_spec.rb
|
272
|
+
- spec/metanorma/base_spec.rb
|
273
|
+
- spec/metanorma/blocks_spec.rb
|
274
|
+
- spec/metanorma/cleanup_spec.rb
|
275
|
+
- spec/metanorma/iev_spec.rb
|
276
|
+
- spec/metanorma/inline_spec.rb
|
277
|
+
- spec/metanorma/lists_spec.rb
|
280
278
|
- spec/metanorma/processor_spec.rb
|
279
|
+
- spec/metanorma/section_spec.rb
|
280
|
+
- spec/metanorma/validate_spec.rb
|
281
281
|
- spec/spec_helper.rb
|
282
282
|
homepage: https://github.com/metanorma/metanorma-iec
|
283
283
|
licenses:
|