require 'tmpdir' require File.expand_path('../../spec_helper', __FILE__) # The CocoaPods namespace # module Pod describe TrySettings do it 'returns an instance with empty defaults when there are no yml settings files' do Dir.mktmpdir do |dir| settings = TrySettings.settings_from_folder dir settings.should.be.instance_of TrySettings settings.pre_install_commands.should.be.nil? settings.project_path.should.be.nil? end end it 'returns an instance with the right defaults when there are no yml settings files' do Dir.mktmpdir do |dir| yaml = <