Sha256: 89ca729b21ba81403f070d2bfa811846e48cb4f6b02224668f73bff7addd85cd
Contents?: true
Size: 931 Bytes
Versions: 4
Compression:
Stored size: 931 Bytes
Contents
require File.join(File.dirname(__FILE__), 'test_helper') class ConfigurationTest < Test::Unit::TestCase context 'Global configuration options' do setup do module Extension; end @options = { 'class_name' => 'CustomVersion', :extend => Extension, :as => :parent } VestalVersions.configure do |config| @options.each do |key, value| config.send("#{key}=", value) end end @configuration = VestalVersions::Configuration.options end should 'should be a hash' do assert_kind_of Hash, @configuration end should 'have symbol keys' do assert @configuration.keys.all?{|k| k.is_a?(Symbol) } end should 'store values identical to those given' do assert_equal @options.symbolize_keys, @configuration end teardown do VestalVersions::Configuration.options.clear end end end
Version data entries
4 entries across 4 versions & 2 rubygems