Sha256: 1d05bae61261ac923bbf00d19ff6ce17eda2cea30764222a082a56a3edc87cb1

Contents?: true

Size: 601 Bytes

Versions: 4

Compression:

Stored size: 601 Bytes

Contents

# encoding: utf-8
require File.expand_path("test/test_helper.rb")

class ThemesForRailsTest < Test::Unit::TestCase
  
  should 'change the base directory' do
    ThemesForRails.config do |config|
      config.base_dir = 'empty_themes'
    end
    
    assert_equal [], ThemesForRails.available_theme_names
  end
  
  should 'change the directory to views' do
    ThemesForRails.config do |config|
      config.themes_dir = ':root/another_themes'
    end
    
    assert_equal ['another_default'], ThemesForRails.available_theme_names
  end
  
  teardown do
    ThemesForRails.config.clear
  end
  
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
themes_for_rails4-1.5.1 test/lib/config_test.rb
themes_for_rails-0.5.1 test/lib/config_test.rb
themes_for_rails-0.5.0 test/lib/config_test.rb
themes_for_rails-0.5.0.pre test/lib/config_test.rb