Sha256: c3820be90c661c8eb4976606618bd8217d4bbe59fbaa7caec008d07e292e5a47
Contents?: true
Size: 531 Bytes
Versions: 8
Compression:
Stored size: 531 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe DataSources::Environment do context '#fetch' do it 'retrieves environment variables' do in_environment 'MY_NAME' => 'Karl' do source = DataSources::Environment.new expect(source.fetch('MY_NAME')).to eq('Karl') end end it 'returns nil if variable cannot be found' do in_environment 'MY_NAME' => 'Karl' do source = DataSources::Environment.new expect(source.fetch('NOT_MY_NAME')).to be_nil end end end end
Version data entries
8 entries across 8 versions & 1 rubygems