public
Rubygem
Description: Simplifies plugin testing by creating an isolated Rails environment that simulates its usage in a real application
Homepage: http://www.pluginaweek.org
Clone URL: git://github.com/pluginaweek/plugin_test_helper.git
Add tests for generators
Improve test coverage
obrie (author)
Tue Jul 01 21:52:04 -0700 2008
commit  fe2ec39a4c204d51617613d218f63974f8a8d85c
tree    862301d1e8f07a7f85fedeeaf961f0dfe73006bd
parent  40ebd62c3e17ab9588c8864ebc3fc030b13a5f3d
...
2
3
4
5
6
 
 
 
 
 
 
 
7
8
9
...
2
3
4
 
 
5
6
7
8
9
10
11
12
13
14
0
@@ -2,8 +2,13 @@
0
 class PluginTestHelperGenerator < Rails::Generator::NamedBase
0
   def manifest #:nodoc:
0
     record do |m|
0
-      plugin_test_root = "vendor/plugins/#{name}/test"
0
-      m.file 'test_helper.rb', "#{plugin_test_root}/test_helper.rb"
0
+      plugin_root = "vendor/plugins/#{name}"
0
+      
0
+      # Test directory
0
+      m.directory File.join(plugin_root, 'test')
0
+      
0
+      # Test helper
0
+      m.file 'test_helper.rb', File.join(plugin_root, 'test/test_helper.rb')
0
     end
0
   end
0
   

Comments