Sha256: 572d420cedeb23558de028d258747585a280af1b00434448039ff736059eef4b

Contents?: true

Size: 1.15 KB

Versions: 26

Compression:

Stored size: 1.15 KB

Contents

require File.dirname(__FILE__) + '/../../../../../spec_helper'
include OpenEHR::RM::Common::Generic

describe Participation do
  before(:each) do
    performer = stub(PartyProxy, :name => 'GEHIRN')
    function = stub(DvText, :value => 'committer')
    mode = stub(DvCodedText, :value => 'present')
    lower = stub(DvDateTime, :value => '2009-10-03T20:33:05')
    time = stub(DvInterval, :lower => lower)
    @participation = Participation.new(:performer => performer,
                                       :function => function,
                                       :mode => mode,
                                       :time => time)
  end

  it 'should be an instance of Participation' do
    @participation.should be_an_instance_of Participation
  end

  it 'should assign performer properly' do
    @participation.performer.name.should == 'GEHIRN'
  end

  it 'should assign function properly' do
    @participation.function.value.should == 'committer'
  end

  it 'should assign mode properly' do
    @participation.mode.value.should == 'present'
  end

  it 'should assign time properly' do
    @participation.time.lower.value.should == '2009-10-03T20:33:05'
  end
end

Version data entries

26 entries across 26 versions & 2 rubygems

Version Path
openehr-1.2.8 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.7 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.6 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.5 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.4 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.3 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.2 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.1 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.2.0 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.6 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.5 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.4 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.3 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.2 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.1 spec/lib/openehr/rm/common/generic/participation_spec.rb
openehr-1.1.0 spec/lib/openehr/rm/common/generic/participation_spec.rb
open_ehr-1.0.2 spec/lib/open_ehr/rm/common/generic/participation_spec.rb
open_ehr-1.0.1 spec/lib/open_ehr/rm/common/generic/participation_spec.rb
open_ehr-1.0.0 spec/lib/open_ehr/rm/common/generic/participation_spec.rb
open_ehr-0.9.5 spec/lib/open_ehr/rm/common/generic/participation_spec.rb