Sha256: 409d2a69b95120e2a706357cc6a26be3ead544a39a85cc56e161fa361378b286

Contents?: true

Size: 973 Bytes

Versions: 26

Compression:

Stored size: 973 Bytes

Contents

require File.dirname(__FILE__) + '/../../../../spec_helper'
include OpenEHR::RM::EHR
include OpenEHR::RM::Security
include OpenEHR::RM::DataTypes::Text

describe EHRAccess do
  before(:each) do
    name = DvText.new(:value => 'EHRAccess')
    settings = stub(AccessControlSettings)
    @ehr_access = EHRAccess.new(:archetype_node_id => 'at0001',
                                :name => name,
                                :settings => settings,
                                :scheme => 'SSL')
  end

  it 'should be an instance of EHRAccess' do
    @ehr_access.should be_an_instance_of EHRAccess
  end

  it 'settings should be assigned, but Security package is not determined' do
    @ehr_access.settings.should_not be_nil
  end

  it 'schema should be assigned properly' do
    @ehr_access.scheme.should == 'SSL'
  end

  it 'should raise ArgumentError with nil schema' do
    lambda {
      @ehr_access.scheme = nil
    }.should raise_error ArgumentError
  end
end

Version data entries

26 entries across 26 versions & 2 rubygems

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