Sha256: 1ddcaa07a1042d72e406cbe9c01c873cad93a1be4e7a0fc3f66b6b3097dd9ad6
Contents?: true
Size: 972 Bytes
Versions: 5
Compression:
Stored size: 972 Bytes
Contents
require 'spec_helper' require_relative '../../../../../lib/locomotive/steam/adapters/filesystem/yaml_loader.rb' require_relative '../../../../../lib/locomotive/steam/adapters/filesystem/yaml_loaders/site.rb' describe Locomotive::Steam::Adapters::Filesystem::YAMLLoaders::Site do let(:site_path) { default_fixture_site_path } let(:loader) { described_class.new(site_path) } describe '#load' do subject { loader.load(nil).first } it { expect(subject[:name]).to eq 'Sample site' } describe '#metafields_schema' do subject { loader.load(nil).first[:metafields_schema] } it 'loads the full schema' do expect(subject.count).to eq 4 end end context 'a different environment' do let(:loader) { described_class.new(site_path, :production) } it 'completes the data with the ones from the production environment' do expect(subject[:name]).to eq('My awesome site') end end end end
Version data entries
5 entries across 5 versions & 1 rubygems