Sha256: 80b23cdf8c7171b2e36cdac43d4ce7312006ed722fa5cde119eca433d3ddcebb
Contents?: true
Size: 656 Bytes
Versions: 13
Compression:
Stored size: 656 Bytes
Contents
require 'spec_helper' describe Locomotive::Coal::Resource do let(:attributes) { { 'title' => 'Hello world' } } let(:resource) { described_class.new(attributes) } describe 'unknown attribute' do subject { resource.name } it { expect { subject }.to raise_error } end describe 'existing attribute' do subject { resource.title } it { is_expected.to eq 'Hello world' } end describe '#respond_to?' do let(:name) { :title } subject { resource.respond_to?(name) } it { is_expected.to eq true } context 'unknown attribute' do let(:name) { :body } it { is_expected.to eq false } end end end
Version data entries
13 entries across 13 versions & 1 rubygems