Sha256: 0defe8d60bc7cf66dad47dcd0b24e15ef025cf3182252782d0e07da7502459da
Contents?: true
Size: 788 Bytes
Versions: 2
Compression:
Stored size: 788 Bytes
Contents
require 'spec_helper' describe "The MooTools-Rails railtie" do it "changes the default javascript expansion" do get_js_defaults("default").should == ["mootools.min", "rails"].inspect end it "uses non-minified js in development" do get_js_defaults("default", "development").should == %w(mootools rails).inspect end it "changes allows overriding the javascript expansion" do get_js_defaults("custom").should == ["foo", "bar", "baz"].inspect end def get_js_defaults(name, env = "production") dir = File.expand_path("../../support/#{name}_app", __FILE__) Dir.chdir(dir) do `bundle install --local` `rails runner -e #{env} 'puts Rails.application.config.action_view. javascript_expansions[:defaults].inspect'`.chomp end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
mootools-rails-0.2 | spec/lib/mootools-rails_spec.rb |
mootools-rails-0.1 | spec/lib/mootools-rails_spec.rb |