aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/plugins/vendored_test.rb
blob: 71de542ff79663f92f4a742a9c6ba62372a6a907 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
require "isolation/abstract_unit"

module ApplicationTests
  class PluginTest < Test::Unit::TestCase
    include ActiveSupport::Testing::Isolation

    def setup
      build_app
    end

    test "generates the plugin" do
      script "generate plugin my_plugin"
      File.open("#{app_path}/vendor/plugins/my_plugin/init.rb", 'w') do |f|
        f.puts "OMG = 'hello'"
      end
      require "#{app_path}/config/environment"
    end
  end
end