reqif 0.2.0 → 0.2.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 455355645036e719c0878c741609fb0b23c4edbc4f0b5a221db0513a142c4e72
4
- data.tar.gz: 6d44e1233fb002d17ee4e371f240dd5d8eb25e7df99f571becbd96e6bc86e373
3
+ metadata.gz: 87f7443f682db3cfbf6c07bed189c5d915c13a99985cff0a71858b7607eaf0ee
4
+ data.tar.gz: ffa41c9adebd58385b1295a5213ac0f7903a91852bf2b973e2e51e61f43333de
5
5
  SHA512:
6
- metadata.gz: 5d8fab36ee06d539bfef358c7bbd3f410ca35ec10e37e40d932b0bb3f12056644b7c7ad572a096898611097e7b5e666be99effe7b240a62b8d69decdde97672e
7
- data.tar.gz: a44955c71b98fcea4d13240165e3bd7e6b9502c16bb485f797f3af062f1234ae1ed49076d60fdea43e93333582ec6966687f19988de10560271d80962650e540
6
+ metadata.gz: 295628518ebcaa3f5ac4a88879130c7dc1dcd676e385d4503efae28b82e87c5cb6538f58e422c4b45d08c94e9b52a2c6793d02f6324fdb5a806a0f5038bed916
7
+ data.tar.gz: dce2e1be0c0683d7f42fd86aacd74f444858053b3ae18e1df50e51335b4c249faad6dc0efb736f92afd72574a9302ebccbad63f0d5415073bc6c8ef6fd51ef9d
data/.rubocop_todo.yml CHANGED
@@ -1,159 +1,26 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config`
3
- # on 2026-04-01 07:11:02 UTC using RuboCop version 1.86.0.
3
+ # on 2026-04-20 22:54:00 UTC using RuboCop version 1.86.1.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
7
7
  # versions of RuboCop, may require this file to be generated again.
8
8
 
9
- # Offense count: 17
10
- # This cop supports safe autocorrection (--autocorrect).
11
- # Configuration parameters: TreatCommentsAsGroupSeparators, ConsiderPunctuation.
12
- Bundler/OrderedGems:
13
- Exclude:
14
- - 'Gemfile'
15
-
16
- # Offense count: 1
17
- # This cop supports safe autocorrection (--autocorrect).
18
- # Configuration parameters: TreatCommentsAsGroupSeparators, ConsiderPunctuation.
19
- Gemspec/OrderedDependencies:
20
- Exclude:
21
- - 'reqif.gemspec'
22
-
23
- # Offense count: 1
24
- # This cop supports safe autocorrection (--autocorrect).
25
- Gemspec/RequireMFA:
26
- Exclude:
27
- - 'reqif.gemspec'
28
-
29
- # Offense count: 63
30
- # This cop supports safe autocorrection (--autocorrect).
31
- # Configuration parameters: EnforcedStyle, IndentationWidth.
32
- # SupportedStyles: with_first_argument, with_fixed_indentation
33
- Layout/ArgumentAlignment:
34
- Exclude:
35
- - 'lib/reqif.rb'
36
- - 'lib/reqif/datatypes.rb'
37
- - 'lib/reqif/default_value.rb'
38
- - 'lib/reqif/definition.rb'
39
- - 'lib/reqif/doors/readonly_attributes.rb'
40
- - 'lib/reqif/editable_atts.rb'
41
- - 'lib/reqif/reqif_float.rb'
42
- - 'lib/reqif/spec_attributes.rb'
43
- - 'lib/reqif/type.rb'
44
- - 'lib/reqif/values.rb'
45
-
46
- # Offense count: 2
47
- # This cop supports safe autocorrection (--autocorrect).
48
- Layout/ClosingParenthesisIndentation:
49
- Exclude:
50
- - 'spec/reqif/polarion_export_spec.rb'
51
- - 'spec/spec_helper.rb'
52
-
53
- # Offense count: 22
54
- # This cop supports safe autocorrection (--autocorrect).
55
- # Configuration parameters: AllowForAlignment.
56
- Layout/CommentIndentation:
57
- Exclude:
58
- - 'lib/reqif/doors/module_definition.rb'
59
- - 'lib/reqif/doors/readonly_attributes.rb'
60
- - 'lib/reqif/doors/rif_definition.rb'
61
- - 'lib/reqif/req_if_tool_extension.rb'
62
-
63
- # Offense count: 1
64
- # This cop supports safe autocorrection (--autocorrect).
65
- Layout/ElseAlignment:
66
- Exclude:
67
- - 'spec/spec_helper.rb'
68
-
69
- # Offense count: 1
70
- # This cop supports safe autocorrection (--autocorrect).
71
- # Configuration parameters: EnforcedStyle.
72
- # SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines, beginning_only, ending_only
73
- Layout/EmptyLinesAroundClassBody:
74
- Exclude:
75
- - 'lib/reqif/req_if_tool_extension.rb'
76
-
77
- # Offense count: 2
78
- # This cop supports safe autocorrection (--autocorrect).
79
- # Configuration parameters: EnforcedStyle, IndentationWidth.
80
- # SupportedStyles: consistent, consistent_relative_to_receiver, special_for_inner_method_call, special_for_inner_method_call_in_parentheses
81
- Layout/FirstArgumentIndentation:
82
- Exclude:
83
- - 'spec/reqif/polarion_export_spec.rb'
84
- - 'spec/spec_helper.rb'
85
-
86
- # Offense count: 4
87
- # This cop supports safe autocorrection (--autocorrect).
88
- # Configuration parameters: EnforcedStyle.
89
- # SupportedStyles: normal, indented_internal_methods
90
- Layout/IndentationConsistency:
91
- Exclude:
92
- - 'lib/reqif/doors/readonly_attributes.rb'
93
- - 'reqif.gemspec'
94
-
95
- # Offense count: 10
96
- # This cop supports safe autocorrection (--autocorrect).
97
- # Configuration parameters: Width, EnforcedStyleAlignWith, AllowedPatterns.
98
- # SupportedStylesAlignWith: start_of_line, relative_to_receiver
99
- Layout/IndentationWidth:
100
- Exclude:
101
- - 'lib/reqif/doors/readonly_attributes.rb'
102
- - 'spec/spec_helper.rb'
103
-
104
- # Offense count: 78
9
+ # Offense count: 14
105
10
  # This cop supports safe autocorrection (--autocorrect).
106
11
  # Configuration parameters: Max, AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
107
12
  # URISchemes: http, https
108
13
  Layout/LineLength:
109
- Enabled: false
110
-
111
- # Offense count: 1
112
- # This cop supports safe autocorrection (--autocorrect).
113
- # Configuration parameters: EnforcedStyle.
114
- # SupportedStyles: symmetrical, new_line, same_line
115
- Layout/MultilineMethodCallBraceLayout:
116
14
  Exclude:
15
+ - 'lib/reqif/doors/string_type.rb'
16
+ - 'lib/reqif/high_precision_date_time.rb'
17
+ - 'lib/reqif/namespace.rb'
18
+ - 'lib/reqif/reqif_integer.rb'
117
19
  - 'spec/reqif/polarion_export_spec.rb'
118
-
119
- # Offense count: 1
120
- # This cop supports safe autocorrection (--autocorrect).
121
- # Configuration parameters: EnforcedStyle, IndentationWidth.
122
- # SupportedStyles: aligned, indented
123
- Layout/MultilineOperationIndentation:
124
- Exclude:
20
+ - 'spec/reqif/spec_types_spec.rb'
21
+ - 'spec/reqif/specifications_spec.rb'
125
22
  - 'spec/reqif_spec.rb'
126
-
127
- # Offense count: 8
128
- # This cop supports safe autocorrection (--autocorrect).
129
- # Configuration parameters: EnforcedStyle.
130
- # SupportedStyles: final_newline, final_blank_line
131
- Layout/TrailingEmptyLines:
132
- Exclude:
133
- - 'lib/reqif/doors/identifier.rb'
134
- - 'lib/reqif/doors/module_definition.rb'
135
- - 'lib/reqif/doors/namespace.rb'
136
- - 'lib/reqif/doors/readonly_attributes.rb'
137
- - 'lib/reqif/doors/rif_definition.rb'
138
- - 'lib/reqif/doors/string_type.rb'
139
- - 'lib/reqif/string_type.rb'
140
- - 'lib/reqif/xhtml/namespace.rb'
141
-
142
- # Offense count: 63
143
- # This cop supports safe autocorrection (--autocorrect).
144
- # Configuration parameters: AllowInHeredoc.
145
- Layout/TrailingWhitespace:
146
- Exclude:
147
- - 'lib/reqif.rb'
148
- - 'lib/reqif/datatypes.rb'
149
- - 'lib/reqif/default_value.rb'
150
- - 'lib/reqif/definition.rb'
151
- - 'lib/reqif/doors/readonly_attributes.rb'
152
- - 'lib/reqif/editable_atts.rb'
153
- - 'lib/reqif/reqif_float.rb'
154
- - 'lib/reqif/spec_attributes.rb'
155
- - 'lib/reqif/type.rb'
156
- - 'lib/reqif/values.rb'
23
+ - 'spec/spec_helper.rb'
157
24
 
158
25
  # Offense count: 1
159
26
  # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns, inherit_mode.
@@ -187,14 +54,6 @@ RSpec/ExampleLength:
187
54
  RSpec/MultipleExpectations:
188
55
  Max: 8
189
56
 
190
- # Offense count: 1
191
- # This cop supports safe autocorrection (--autocorrect).
192
- # Configuration parameters: EnforcedStyle.
193
- # SupportedStyles: not_to, to_not
194
- RSpec/NotToNot:
195
- Exclude:
196
- - 'spec/reqif/polarion_export_spec.rb'
197
-
198
57
  # Offense count: 2
199
58
  # Configuration parameters: CustomTransform, IgnoreMethods, IgnoreMetadata, InflectorPath, EnforcedInflector.
200
59
  # SupportedInflectors: default, active_support
@@ -202,40 +61,3 @@ RSpec/SpecFilePathFormat:
202
61
  Exclude:
203
62
  - 'spec/reqif/data_types_spec.rb'
204
63
  - 'spec/reqif/tool_extension_spec.rb'
205
-
206
- # Offense count: 2
207
- # This cop supports safe autocorrection (--autocorrect).
208
- # Configuration parameters: EnforcedStyle.
209
- # SupportedStyles: separated, grouped
210
- Style/AccessorGrouping:
211
- Exclude:
212
- - 'lib/reqif/high_precision_date_time.rb'
213
-
214
- # Offense count: 1
215
- # This cop supports safe autocorrection (--autocorrect).
216
- # Configuration parameters: AllowIfModifier.
217
- Style/IfInsideElse:
218
- Exclude:
219
- - 'spec/spec_helper.rb'
220
-
221
- # Offense count: 1
222
- # This cop supports safe autocorrection (--autocorrect).
223
- Style/MultilineIfModifier:
224
- Exclude:
225
- - 'lib/reqif/reqif_float.rb'
226
-
227
- # Offense count: 2
228
- # This cop supports safe autocorrection (--autocorrect).
229
- # Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
230
- # SupportedStyles: single_quotes, double_quotes
231
- Style/StringLiterals:
232
- Exclude:
233
- - 'reqif.gemspec'
234
-
235
- # Offense count: 1
236
- # This cop supports safe autocorrection (--autocorrect).
237
- # Configuration parameters: EnforcedStyleForMultiline.
238
- # SupportedStylesForMultiline: comma, consistent_comma, diff_comma, no_comma
239
- Style/TrailingCommaInArguments:
240
- Exclude:
241
- - 'spec/reqif/req_if_spec.rb'
data/Gemfile CHANGED
@@ -7,6 +7,7 @@ gemspec
7
7
 
8
8
  gem "canon"
9
9
  gem "lutaml-model", github: "lutaml/lutaml-model", branch: "main"
10
+ gem "moxml"
10
11
  gem "nokogiri"
11
12
  gem "rake", "~> 13.0"
12
13
  gem "rspec", "~> 3.0"
@@ -67,6 +67,7 @@ module Reqif
67
67
 
68
68
  def self.cast(value, options = {})
69
69
  return nil if value.nil?
70
+ return value if Lutaml::Model::Utils.uninitialized?(value)
70
71
 
71
72
  unless options.equal?(EMPTY_OPTIONS)
72
73
  Lutaml::Model::Services::Type::Validator::Number.validate!(value,
data/lib/reqif/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Reqif
4
- VERSION = "0.2.0"
4
+ VERSION = "0.2.1"
5
5
  end
@@ -82,8 +82,7 @@ module Reqif
82
82
  attribute :rp, Hyperlang::Xhtml::Rp, collection: true
83
83
  attribute :rbc, Hyperlang::Xhtml::Rbc, collection: true
84
84
  attribute :rtc, Hyperlang::Xhtml::Rtc, collection: true
85
- attribute :content, :string
86
-
85
+ attribute :content, :string, collection: true
87
86
  xml do
88
87
  element "XHTML-CONTENT"
89
88
  namespace Namespace
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: reqif
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-04-01 00:00:00.000000000 Z
11
+ date: 2026-04-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hyperlang