lib/metanorma/ogc/cleanup.rb in metanorma-ogc-2.1.5 vs lib/metanorma/ogc/cleanup.rb in metanorma-ogc-2.2.0
- old
+ new
@@ -120,9 +120,16 @@
super
xmldoc.xpath(REQRECPER).each do |r|
requirement_metadata_to_component(r)
requirement_metadata_to_requirement(r)
requirement_subparts_to_blocks(r)
+ requirement_target_identifiers(r)
+ end
+ end
+
+ def requirement_target_identifiers(reqt)
+ reqt.xpath("./classification[tag = 'target']/value[link]").each do |v|
+ v.children = v.at("./link/@target").text
end
end
def requirement_metadata_to_component(reqt)
reqt.xpath(".//test-method | .//test-purpose | .//conditions | "\