1 | require 'test/unit'
|
---|
2 | require 'set'
|
---|
3 | require 'rm'
|
---|
4 |
|
---|
5 | include OpenEHR::RM::Data_Types::Text
|
---|
6 | include OpenEHR::RM::Common::Resource
|
---|
7 | include OpenEHR::RM::Common::Archetyped
|
---|
8 | include OpenEHR::RM::Common::Generic
|
---|
9 | include OpenEHR::RM::Common::Change_Control
|
---|
10 | include OpenEHR::RM::Support::Identification
|
---|
11 | include OpenEHR::RM::Data_Types::Basic
|
---|
12 | include OpenEHR::RM::Data_Types::Quantity
|
---|
13 | include OpenEHR::RM::Data_Types::URI
|
---|
14 |
|
---|
15 | class RM_Common_Resource_Test < Test::Unit::TestCase
|
---|
16 | def setup
|
---|
17 | @authored_resource = OpenEHR::RM::Common::Resource::AUTHORED_RESOURCE.new(:original_language => "ja",
|
---|
18 | :translations => "en",
|
---|
19 | :description => "test")
|
---|
20 | @translation_details = OpenEHR::RM::Common::Resource::TRANSLATION_DETAILS.new(nil,nil,nil,nil,nil)
|
---|
21 | end
|
---|
22 | def test_init
|
---|
23 | assert_instance_of OpenEHR::RM::Common::Resource::AUTHORED_RESOURCE, @authored_resource
|
---|
24 | assert_instance_of OpenEHR::RM::Common::Resource::TRANSLATION_DETAILS, @translation_details
|
---|
25 | end
|
---|
26 |
|
---|
27 | def test_authoured_resource
|
---|
28 | assert_equal 'ja', @authored_resource.original_language
|
---|
29 | end
|
---|
30 | end
|
---|
31 |
|
---|
32 |
|
---|
33 | class RM_Common_Archetyped_Test < Test::Unit::TestCase
|
---|
34 | def setup
|
---|
35 | @dv_text = OpenEHR::RM::Data_Types::Text::DV_Text.new('Test')
|
---|
36 | @uid_based_id = OpenEHR::RM::Support::Identification::UID_Based_ID.new('rrip::0.0.5')
|
---|
37 | @archetype_id = OpenEHR::RM::Support::Identification::Archetype_ID.new("0.0.5", "biochemistry result_cholesterol", "entry", "ehr_rm", "openehr","cholesterol","0.0.3")
|
---|
38 | @template_id = OpenEHR::RM::Support::Identification::Template_ID.new('1.0.1')
|
---|
39 | assert_nothing_raised(Exception){@archetyped = OpenEHR::RM::Common::Archetyped::Archetyped.new(@archetype_id, '1.0.1')}
|
---|
40 | assert_nothing_raised(Exception){@link = OpenEHR::RM::Common::Archetyped::Link.new(OpenEHR::RM::Data_Types::Text::DV_Text.new("generic"), OpenEHR::RM::Data_Types::URI::DV_EHR_URI.new("ehr://test/"),OpenEHR::RM::Data_Types::Text::DV_Text.new("problem"))}
|
---|
41 | assert_nothing_raised(Exception){
|
---|
42 | @pathable = OpenEHR::RM::Common::Archetyped::Pathable.new }
|
---|
43 | name = OpenEHR::RM::Data_Types::Text::DV_Text.new('blood')
|
---|
44 | links = Set.new([@uid_based_id])
|
---|
45 | assert_nothing_raised(Exception){
|
---|
46 | @locatable = OpenEHR::RM::Common::Archetyped::Locatable.new('at0001',name,links)}
|
---|
47 | provider = Party_Identified.new(:name => 'NERV')
|
---|
48 | location = Party_Identified.new(:name => 'GEOFRONT')
|
---|
49 | object_version_id = Object_Version_ID.new('ABC::DEF::1.3.4')
|
---|
50 | party_ref = Party_Ref.new('local', 'ORGANISATION', object_id)
|
---|
51 | assert_nothing_raised(Exception){
|
---|
52 | @feeder_audit_details = Feeder_Audit_Details.new(:system_id => 'MAGI',
|
---|
53 | :provider => provider,
|
---|
54 | :location => location,
|
---|
55 | :time => DV_Date_Time.new('2009-07-03T12:16:31'),
|
---|
56 | :subject => Party_Proxy.new(:external_ref => party_ref),
|
---|
57 | :version_id => '0.0.4')}
|
---|
58 | feeder_audit_details = Feeder_Audit_Details.new(:system_id => 'AKAGI')
|
---|
59 | dv_identifier = DV_Identifier.new('NERV', 'MELCHIOR', 'RITSUKO', 'COMPUTER')
|
---|
60 | feeder_audit_details2 = Feeder_Audit_Details.new(:system_id => 'KATSURAGI')
|
---|
61 | dv_identifier2 = DV_Identifier.new('NERV', 'SHOGOUKI', 'MISATO', 'EVANGELION')
|
---|
62 | charset = OpenEHR::RM::Data_Types::Text::Code_Phrase.new('UTF-8','character-sets')
|
---|
63 | language = OpenEHR::RM::Data_Types::Text::Code_Phrase.new('ja', 'languages')
|
---|
64 |
|
---|
65 | dv_encapsulated = OpenEHR::RM::Data_Types::Encapsulated::DV_Encapsulated.new(charset, language, 10)
|
---|
66 | assert_nothing_raised(Exception){
|
---|
67 | @feeder_audit = Feeder_Audit.new(:originating_system_audit => feeder_audit_details,
|
---|
68 | :originating_system_item_ids => [dv_identifier],
|
---|
69 | :feeder_system_audit => feeder_audit_details2,
|
---|
70 | :feeder_system_item_ids => [dv_identifier2],
|
---|
71 | :original_content => dv_encapsulated)}
|
---|
72 | end
|
---|
73 |
|
---|
74 | def test_init
|
---|
75 | assert_instance_of OpenEHR::RM::Common::Archetyped::Archetyped, @archetyped
|
---|
76 | assert_instance_of OpenEHR::RM::Common::Archetyped::Link, @link
|
---|
77 | assert_instance_of OpenEHR::RM::Common::Archetyped::Pathable, @pathable
|
---|
78 | assert_instance_of OpenEHR::RM::Common::Archetyped::Locatable, @locatable
|
---|
79 | assert_instance_of Feeder_Audit_Details, @feeder_audit_details
|
---|
80 | assert_instance_of Feeder_Audit, @feeder_audit
|
---|
81 | end
|
---|
82 |
|
---|
83 | def test_archetyped
|
---|
84 | assert_equal @archetype_id, @archetyped.archetype_id
|
---|
85 | assert_equal '1.0.1', @archetyped.rm_version
|
---|
86 | assert_raise(ArgumentError){@archetyped.archetype_id = nil}
|
---|
87 | assert_raise(ArgumentError){@archetyped.rm_version = nil}
|
---|
88 | assert_raise(ArgumentError){@archetyped.rm_version = ''}
|
---|
89 | assert_nothing_raised(Exception){@archetyped.template_id = @template_id}
|
---|
90 | assert_equal @template_id, @archetyped.template_id
|
---|
91 | archetype_id2 = OpenEHR::RM::Support::Identification::Archetype_ID.new("1.0.2", "biochemistry result_cholesterol", "entry", "ehr_rm", "openehr","cholesterol","0.0.3")
|
---|
92 | assert_nothing_raised(ArgumentError){@archetyped.archetype_id = archetype_id2}
|
---|
93 | assert_equal archetype_id2, @archetyped.archetype_id
|
---|
94 | assert_nothing_raised(ArgumentError){@archetyped.rm_version = '1.0.2'}
|
---|
95 | assert_equal '1.0.2', @archetyped.rm_version
|
---|
96 | end
|
---|
97 |
|
---|
98 | def test_link
|
---|
99 | # test constructor
|
---|
100 | assert_equal 'generic', @link.meaning.value
|
---|
101 | assert_equal 'ehr://test/', @link.target.value
|
---|
102 | assert_equal 'problem', @link.type.value
|
---|
103 | # test meaning
|
---|
104 | assert_nothing_raised(Exception){@link.meaning = OpenEHR::RM::Data_Types::Text::DV_Text.new('clinical')}
|
---|
105 | assert_equal 'clinical', @link.meaning.value
|
---|
106 | assert_raise(ArgumentError){@link.meaning = nil}
|
---|
107 | # test target
|
---|
108 | assert_nothing_raised(Exception){@link.target = OpenEHR::RM::Data_Types::URI::DV_EHR_URI.new("ehr://try/")}
|
---|
109 | assert_equal 'ehr://try/', @link.target.value
|
---|
110 | assert_raise(ArgumentError){@link.target = nil}
|
---|
111 | # test type
|
---|
112 | assert_nothing_raised(Exception){@link.type = OpenEHR::RM::Data_Types::Text::DV_Text.new("issue")}
|
---|
113 | assert_equal 'issue', @link.type.value
|
---|
114 | assert_raise(ArgumentError){@link.type = nil}
|
---|
115 | end
|
---|
116 |
|
---|
117 | def test_feeder_audit
|
---|
118 | assert_equal 'AKAGI', @feeder_audit.originating_system_audit.system_id
|
---|
119 | assert_equal 'RITSUKO', @feeder_audit.originating_system_item_ids[0].issuer
|
---|
120 | assert_equal 'KATSURAGI', @feeder_audit.feeder_system_audit.system_id
|
---|
121 | assert_equal 'MISATO', @feeder_audit.feeder_system_item_ids[0].issuer
|
---|
122 | assert_equal 'UTF-8', @feeder_audit.original_content.charset.code_string
|
---|
123 | end
|
---|
124 |
|
---|
125 | def test_feeder_audit_detail
|
---|
126 | assert_equal 'MAGI', @feeder_audit_details.system_id
|
---|
127 | assert_equal 'NERV', @feeder_audit_details.provider.name
|
---|
128 | assert_equal 'GEOFRONT', @feeder_audit_details.location.name
|
---|
129 | assert_equal 2009, @feeder_audit_details.time.year
|
---|
130 | assert_equal 'local', @feeder_audit_details.subject.external_ref.namespace
|
---|
131 | assert_equal '0.0.4', @feeder_audit_details.version_id
|
---|
132 | end
|
---|
133 | end
|
---|
134 |
|
---|
135 | class RM_Common_Generic_Test < Test::Unit::TestCase
|
---|
136 | def setup
|
---|
137 | assert_nothing_raised(Exception){party_proxy = Party_Proxy.new}
|
---|
138 | object_id = Object_ID.new('0.0.4')
|
---|
139 | party_ref = Party_Ref.new('unknown', 'ORGANISATION', object_id)
|
---|
140 | assert_nothing_raised(Exception){
|
---|
141 | @party_proxy = Party_Proxy.new(:external_ref => party_ref)}
|
---|
142 | assert_nothing_raised(Exception){party_self = Party_Self.new}
|
---|
143 | assert_nothing_raised(Exception){
|
---|
144 | @party_self = Party_Self.new(:external_ref => party_ref)}
|
---|
145 | assert_raise(ArgumentError){
|
---|
146 | party_identified = Party_Identified.new}
|
---|
147 |
|
---|
148 | identifiers = []
|
---|
149 | identifiers << DV_Identifier.new('NERV', 'MELCHIOR', 'GENDO', 'COMPUTER')
|
---|
150 | identifiers << DV_Identifier.new('NERV', 'CASPER', 'GENDO', 'COMPUTER')
|
---|
151 | identifiers << DV_Identifier.new('NERV', 'BALTHAZAR', 'GENDO', 'COMPUTER')
|
---|
152 | assert_nothing_raised(Exception){
|
---|
153 | @party_identified = Party_Identified.new(:name => 'NERV',
|
---|
154 | :external_ref => party_ref,
|
---|
155 | :identifier => identifiers)}
|
---|
156 |
|
---|
157 | terminology_id = Terminology_ID.new('test(0.04)')
|
---|
158 | code_phrase = Code_Phrase.new('self', terminology_id)
|
---|
159 | dv_coded_text = DV_Coded_Text.new('Seele',code_phrase)
|
---|
160 | assert_nothing_raised(Exception){
|
---|
161 | @party_related = Party_Related.new(:name => 'GEHIRN',
|
---|
162 | :relationship => dv_coded_text)}
|
---|
163 | dv_text = DV_Text.new('commiter')
|
---|
164 | dv_coded_text = DV_Coded_Text.new('present',terminology_id)
|
---|
165 | dv_date_time1 = DV_Date_Time.new('2009-07-04T16:30:00')
|
---|
166 | dv_date_time2 = DV_Date_Time.new('2009-07-14T00:00:00')
|
---|
167 | dv_interval = DV_Interval.new(dv_date_time1, dv_date_time2)
|
---|
168 | assert_nothing_raised(Exception){
|
---|
169 | @participation = Participation.new(:performer => @party_proxy,
|
---|
170 | :function => dv_text,
|
---|
171 | :mode => dv_coded_text,
|
---|
172 | :time => dv_interval)}
|
---|
173 | dv_date_time = DV_Date_Time.new('2009-07-04T18:56:00')
|
---|
174 | terminology_id = Terminology_ID.new('openehr(1.0.2)')
|
---|
175 | code_phrase = Code_Phrase.new('249', terminology_id)
|
---|
176 | dv_coded_text = DV_Coded_Text.new('creation', code_phrase)
|
---|
177 | dv_text = DV_Text.new('test environment')
|
---|
178 | assert_nothing_raised(Exception){
|
---|
179 | @audit_details = Audit_Details.new(:system_id => 'MAGI',
|
---|
180 | :committer => @party_proxy,
|
---|
181 | :time_committed => dv_date_time,
|
---|
182 | :change_type => dv_coded_text,
|
---|
183 | :description => dv_text)}
|
---|
184 | dv_text = DV_Text.new('authorisation')
|
---|
185 | dv_ehr_uri = DV_EHR_URI.new('ehr://test/')
|
---|
186 | assert_nothing_raised(Exception){
|
---|
187 | @attestation = Attestation.new(:system_id => 'NERV',
|
---|
188 | :committer => @party_proxy,
|
---|
189 | :time_committed => dv_date_time,
|
---|
190 | :change_type => dv_coded_text,
|
---|
191 | :reason => dv_text,
|
---|
192 | :description => dv_text,
|
---|
193 | :proof => 'hashedstring',
|
---|
194 | :items => Set[dv_ehr_uri])}
|
---|
195 | object_version_id = Object_Version_ID.new('SHOGOUKI::NERV::1.1.1')
|
---|
196 | audit_details2 = Audit_Details.new(:system_id => 'MAGI',
|
---|
197 | :committer => @party_proxy,
|
---|
198 | :time_committed => dv_date_time2,
|
---|
199 | :change_type => dv_coded_text)
|
---|
200 | assert_nothing_raised(Exception){
|
---|
201 | @revision_history_item = Revision_History_Item.new(:audits => [@audit_details, audit_details2],
|
---|
202 | :version_id => object_version_id)}
|
---|
203 | dv_date_time3 = DV_Date_Time.new('2009-07-14T12:00:00')
|
---|
204 | dv_date_time4 = DV_Date_Time.new('2009-07-15T00:00:00')
|
---|
205 | audit_details3 = Audit_Details.new(:system_id => 'MAGI',
|
---|
206 | :committer => @party_proxy,
|
---|
207 | :time_committed => dv_date_time3,
|
---|
208 | :change_type => dv_coded_text)
|
---|
209 | audit_details4 = Audit_Details.new(:system_id => 'MAGI',
|
---|
210 | :committer => @party_proxy,
|
---|
211 | :time_committed => dv_date_time4,
|
---|
212 | :change_type => dv_coded_text)
|
---|
213 | object_version_id = Object_Version_ID.new('NIGOUKI::NERV::2.2.2')
|
---|
214 | revision_history_item2 = Revision_History_Item.new(:audits => [audit_details3, audit_details4],
|
---|
215 | :version_id => object_version_id)
|
---|
216 | assert_nothing_raised(Exception){
|
---|
217 | @revision_history = Revision_History.new([@revision_history_item, revision_history_item2])}
|
---|
218 | end
|
---|
219 |
|
---|
220 | def test_init
|
---|
221 | assert_instance_of Party_Proxy, @party_proxy
|
---|
222 | assert_instance_of Party_Self, @party_self
|
---|
223 | assert_instance_of Party_Identified, @party_identified
|
---|
224 | assert_instance_of Participation, @participation
|
---|
225 | assert_instance_of Audit_Details, @audit_details
|
---|
226 | assert_instance_of Attestation, @attestation
|
---|
227 | assert_instance_of Revision_History_Item, @revision_history_item
|
---|
228 | assert_instance_of Revision_History, @revision_history
|
---|
229 | end
|
---|
230 |
|
---|
231 | def test_party_proxy
|
---|
232 | assert_equal 'unknown', @party_proxy.external_ref.namespace
|
---|
233 | end
|
---|
234 |
|
---|
235 | def test_party_self
|
---|
236 | assert_equal 'ORGANISATION', @party_self.external_ref.type
|
---|
237 | end
|
---|
238 |
|
---|
239 | def test_party_identified
|
---|
240 | assert_equal 'NERV', @party_identified.name
|
---|
241 | assert_equal '0.0.4', @party_identified.external_ref.id.value
|
---|
242 | identifiers = @party_identified.identifier
|
---|
243 | ids = [ ]
|
---|
244 | identifiers.each do |id|
|
---|
245 | ids << id.id
|
---|
246 | end
|
---|
247 | assert_equal %w[MELCHIOR CASPER BALTHAZAR], ids
|
---|
248 | end
|
---|
249 |
|
---|
250 | def test_party_related
|
---|
251 | assert_equal 'GEHIRN', @party_related.name
|
---|
252 | end
|
---|
253 |
|
---|
254 | def test_participation
|
---|
255 | assert_equal 'unknown', @participation.performer.external_ref.namespace
|
---|
256 | assert_equal 'commiter', @participation.function.value
|
---|
257 | assert_equal 'present', @participation.mode.value
|
---|
258 | assert_equal 2009, @participation.time.lower.year
|
---|
259 | end
|
---|
260 |
|
---|
261 | def test_audit_details
|
---|
262 | assert_equal 'MAGI', @audit_details.system_id
|
---|
263 | assert_equal 'unknown', @audit_details.committer.external_ref.namespace
|
---|
264 | assert_equal '2009-07-04T18:56:00', @audit_details.time_committed.as_string
|
---|
265 | assert_equal 'creation', @audit_details.change_type.value
|
---|
266 | assert_equal 'test environment', @audit_details.description.value
|
---|
267 | end
|
---|
268 |
|
---|
269 | def test_attestation
|
---|
270 | assert_equal 'NERV', @attestation.system_id
|
---|
271 | assert_equal 'unknown', @attestation.committer.external_ref.namespace
|
---|
272 | assert_equal '249', @attestation.change_type.defining_code.code_string
|
---|
273 | assert_equal 7, @attestation.time_committed.month
|
---|
274 | assert_equal 'authorisation', @attestation.reason.value
|
---|
275 | assert_equal 'authorisation', @attestation.description.value
|
---|
276 | assert_equal 'hashedstring', @attestation.proof
|
---|
277 | assert_equal 'ehr://test/', @attestation.items.to_a[0].value
|
---|
278 | end
|
---|
279 |
|
---|
280 | def test_revision_history_item
|
---|
281 | assert_equal 'SHOGOUKI::NERV::1.1.1', @revision_history_item.version_id.value
|
---|
282 | assert_equal 'MAGI', @revision_history_item.audits[0].system_id
|
---|
283 | end
|
---|
284 |
|
---|
285 | def test_revision_history
|
---|
286 | assert_equal 'NIGOUKI::NERV::2.2.2', @revision_history.most_recent_version
|
---|
287 | assert_equal '2009-07-14T12:00:00', @revision_history.most_recent_version_time_committed
|
---|
288 | end
|
---|
289 | end
|
---|
290 |
|
---|
291 | class RM_Common_Directory_Test < Test::Unit::TestCase
|
---|
292 | def setup
|
---|
293 | dv_text = OpenEHR::RM::Data_Types::Text::DV_Text.new('root')
|
---|
294 | assert_nothing_raised(Exception){@folder = OpenEHR::RM::Common::Directory::Folder.new('at0000', dv_text, nil)}
|
---|
295 | end
|
---|
296 |
|
---|
297 | def test_init
|
---|
298 | assert_instance_of OpenEHR::RM::Common::Directory::Folder, @folder
|
---|
299 | end
|
---|
300 |
|
---|
301 | def test_folder
|
---|
302 | assert_equal 'at0000', @folder.archetype_node_id
|
---|
303 | assert_equal 'root', @folder.name.value
|
---|
304 | end
|
---|
305 | end
|
---|
306 |
|
---|
307 | class RM_Common_Change_Control_Test < Test::Unit::TestCase
|
---|
308 | def setup
|
---|
309 | object_version_id1 = Object_Version_ID.new('ABC::DEF::2.2.3')
|
---|
310 | object_version_id2 = Object_Version_ID.new('GHI::JKL::4.5.6')
|
---|
311 | object_id = Object_ID.new('ehr://uniqueid1020')
|
---|
312 | dv_date_time = DV_Date_Time.new('2009-07-06T21:10:12')
|
---|
313 | party_ref = Party_Ref.new('unknown', 'ORGANISATION', object_id)
|
---|
314 | party_proxy = Party_Proxy.new(:external_ref => party_ref)
|
---|
315 | terminology_id = Terminology_ID.new('openehr(1.0.2)')
|
---|
316 | code_phrase = Code_Phrase.new('249', terminology_id)
|
---|
317 | dv_coded_text = DV_Coded_Text.new('creation', code_phrase)
|
---|
318 | audit_details = Audit_Details.new(:system_id => 'MAGI',
|
---|
319 | :committer => party_proxy,
|
---|
320 | :time_committed => dv_date_time,
|
---|
321 | :change_type => dv_coded_text)
|
---|
322 | code_phrase = Code_Phrase.new('532', terminology_id)
|
---|
323 | dv_coded_text = DV_Coded_Text.new('complete', code_phrase)
|
---|
324 | object_id = Object_ID.new('ehr://test_location')
|
---|
325 | object_ref = Object_Ref.new('local', 'PARTY', object_id)
|
---|
326 | hier_object_id = Hier_Object_ID.new('ABC')
|
---|
327 | assert_nothing_raised(Exception){
|
---|
328 | @version = Version.new(:uid => object_version_id1,
|
---|
329 | :preceding_version_uid => object_version_id2,
|
---|
330 | :lifecycle_state => dv_coded_text,
|
---|
331 | :commit_audit => audit_details,
|
---|
332 | :contribution => object_ref,
|
---|
333 | :signature => 'test_version',
|
---|
334 | :data => 'data')}
|
---|
335 | object_version_id3 = Object_Version_ID.new('MNO::PQR::7.8.9')
|
---|
336 | object_version_id4 = Object_Version_ID.new('STU::VWX::1.2.3')
|
---|
337 | code_phrase = Code_Phrase.new('240', terminology_id)
|
---|
338 | dv_coded_text2 = DV_Coded_Text.new('signed', code_phrase)
|
---|
339 | attestation = Attestation.new(:system_id => 'NERV',
|
---|
340 | :committer => party_proxy,
|
---|
341 | :time_committed => dv_date_time,
|
---|
342 | :change_type => dv_coded_text,
|
---|
343 | :reason => DV_Text.new('signed'))
|
---|
344 | assert_nothing_raised(Exception){
|
---|
345 | @original_version = Original_Version.new(:uid => object_version_id3,
|
---|
346 | :preceding_version_uid => object_version_id4,
|
---|
347 | :other_input_version_uids => Set[object_version_id1, object_version_id2],
|
---|
348 | :commit_audit => audit_details,
|
---|
349 | :contribution => object_ref,
|
---|
350 | :attestations => [attestation],
|
---|
351 | :data => 'data',
|
---|
352 | :lifecycle_state => dv_coded_text)}
|
---|
353 | end
|
---|
354 |
|
---|
355 | def test_init
|
---|
356 | assert_instance_of OpenEHR::RM::Common::Change_Control::Version, @version
|
---|
357 | assert_instance_of Original_Version, @original_version
|
---|
358 | # assert_instance_of OpenEHR::RM::Common::Change_Control::Contribution @contribution
|
---|
359 | end
|
---|
360 |
|
---|
361 | def test_version
|
---|
362 | assert_equal 'ABC::DEF::2.2.3', @version.uid.value
|
---|
363 | assert !@version.uid.version_tree_id.is_first?
|
---|
364 | assert_equal 'GHI::JKL::4.5.6', @version.preceding_version_uid.value
|
---|
365 | assert_equal '532', @version.lifecycle_state.defining_code.code_string
|
---|
366 | assert_equal 'MAGI', @version.commit_audit.system_id
|
---|
367 | assert_equal 'local', @version.contribution.namespace
|
---|
368 | assert_equal 'test_version', @version.signature
|
---|
369 | assert_equal 'ABC', @version.owner_id.value
|
---|
370 | assert_equal 'data', @version.data
|
---|
371 | assert @version.is_branch?
|
---|
372 | end
|
---|
373 |
|
---|
374 | def test_original_version
|
---|
375 | assert_equal 'MNO::PQR::7.8.9', @original_version.uid.value
|
---|
376 | assert_equal 'NERV', @original_version.attestations[0].system_id
|
---|
377 | end
|
---|
378 |
|
---|
379 | def test_contribution
|
---|
380 | # assert_equal @contribution.uid
|
---|
381 | end
|
---|
382 | end
|
---|