Last change
on this file since 388 was 369, checked in by KOBAYASHI, Shinji, 15 years ago |
merge from branches/0.5
|
File size:
763 bytes
|
Line | |
---|
1 | require File.dirname(__FILE__) + '/../../../../../spec_helper'
|
---|
2 | include OpenEHR::RM::Common::Generic
|
---|
3 | include OpenEHR::RM::DataTypes::Text
|
---|
4 | describe PartyRelated do
|
---|
5 | before(:each) do
|
---|
6 | relationship = stub(DvCodedText, :value => 'self')
|
---|
7 | @party_related = PartyRelated.new(:name => 'TEST',
|
---|
8 | :relationship => relationship)
|
---|
9 | end
|
---|
10 |
|
---|
11 | it 'should be an instance of PartyRelated' do
|
---|
12 | @party_related.should be_an_instance_of PartyRelated
|
---|
13 | end
|
---|
14 |
|
---|
15 | it 'should assign relationship properly' do
|
---|
16 | @party_related.relationship.value.should == 'self'
|
---|
17 | end
|
---|
18 |
|
---|
19 | it 'should raise ArgumentError when nil is assigned to relationship' do
|
---|
20 | lambda {
|
---|
21 | @party_related.relationship = nil
|
---|
22 | }.should raise_error ArgumentError
|
---|
23 | end
|
---|
24 | end
|
---|
Note:
See
TracBrowser
for help on using the repository browser.