diff options
author | Carl Lerche <carllerche@mac.com> | 2009-10-21 15:45:11 -0700 |
---|---|---|
committer | Carl Lerche <carllerche@mac.com> | 2009-10-21 15:46:22 -0700 |
commit | 8a0f4564432bef9dde815dd6b768d088cfad16ed (patch) | |
tree | fad65c831ba2d1a11e0bcccf949c01c3fbfb0bad /railties/test/plugins/vendored_test.rb | |
parent | 3e35d30c0cab711fcc9feddd23f2f682f5d0a050 (diff) | |
download | rails-8a0f4564432bef9dde815dd6b768d088cfad16ed.tar.gz rails-8a0f4564432bef9dde815dd6b768d088cfad16ed.tar.bz2 rails-8a0f4564432bef9dde815dd6b768d088cfad16ed.zip |
Refactored railties' isolation tests to be able to run script/* scripts.
Diffstat (limited to 'railties/test/plugins/vendored_test.rb')
-rw-r--r-- | railties/test/plugins/vendored_test.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/railties/test/plugins/vendored_test.rb b/railties/test/plugins/vendored_test.rb new file mode 100644 index 0000000000..71de542ff7 --- /dev/null +++ b/railties/test/plugins/vendored_test.rb @@ -0,0 +1,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
\ No newline at end of file |