Permalink
Browse files

Fix namespace issue on rake remove_tmp. Fix problem with rubigen comm…

…ands that expect an array as the first parameter under Ruby 1.9.
  • Loading branch information...
1 parent 4edb66a commit e7fa7b354d944476f6d97c5dffb5ac67160a9445 @pragdave committed Nov 3, 2009
@@ -23,18 +23,18 @@ def manifest
# Create stubs
m.template_copy_each %w[Rakefile]
- m.template_copy_each "html/all.html"
+ m.template_copy_each %w[html/all.html]
%w[basics building example including_code including_tex table_of_contents user_defined graphviz].each do |template|
- m.file_copy_each "content/#{template}.textile"
+ m.file_copy_each ["content/#{template}.textile"]
end
- m.template_copy_each "config/metadata.yml"
+ m.template_copy_each %w[config/metadata.yml]
%w[build_all].each do |bin|
- m.file_copy_each "bin/#{bin}.rb"
+ m.file_copy_each ["bin/#{bin}.rb"]
end
%w[basic_continuation cc_throw_catch closure_continuation closure_continuation_2].each do |code|
- m.file_copy_each "code/control/#{code}.rb"
+ m.file_copy_each ["code/control/#{code}.rb"]
end
- m.file_copy_each "code/graphviz/graph.dot"
+ m.file_copy_each ["code/graphviz/graph.dot"]
["CollapseCode.html", "Cpp.html", "CrashTest.html", "CSharp.html", "CSS.html",
"Delphi.html", "FirstLine.html", "Index.html", "Java.html", "JavaScript.html",
"NoControls.html", "NoGutter.html", "PHP.html", "Python.html", "Ruby.html",
@@ -48,21 +48,21 @@ def manifest
"Styles/SyntaxHighlighter.css", "Styles/TestPages.css",
"Templates/Test.dwt"
].each do |syntax|
- m.file_copy_each "assets/dp.SyntaxHighlighter/#{syntax}"
+ m.file_copy_each ["assets/dp.SyntaxHighlighter/#{syntax}"]
end
["pressie.css", "print.css", "ruby.png"].each do |asset|
- m.file_copy_each "assets/stylesheets/#{asset}"
+ m.file_copy_each ["assets/stylesheets/#{asset}"]
end
["blank.gif", "bodybg.gif", "framing.css", "iepngfix.htc", "opera.css", "outline.css",
"pretty.css", "print.css", "s5-core.css", "slides.css", "slides.js"
].each do |asset|
- m.file_copy_each "assets/ui/default/#{asset}"
+ m.file_copy_each ["assets/ui/default/#{asset}"]
end
- m.template_copy_each "filters/example_filter.rb"
+ m.template_copy_each ["filters/example_filter.rb"]
["change_code_urls.rb", "upcase_titles.rb"].each do |asset|
- m.file_copy_each "post_processors/#{asset}"
+ m.file_copy_each ["post_processors/#{asset}"]
end
- m.file_copy_each "templates/layout.erb"
+ m.file_copy_each ["templates/layout.erb"]
m.dependency "install_rubigen_scripts", [destination_root, 'codex'],
:shebang => options[:shebang], :collision => :force
@@ -6,7 +6,7 @@ h1. Building HTML Slides
@rake html/xxx.html@
-* If you've created a @content/table_of_contents.textile@, build the whole presentation with
+* If youve created a @content/table_of_contents.textile@, build the whole presentation with
@rake all@
@@ -18,7 +18,7 @@ h1. Running the Presentation
* See the "S5 documentation":http://meyerweb.com/eric/tools/s5/ for details
-* Some hints
+* Some hints
** arrow keys and space bar work
** type the slide number to jump
** mouse over the bottom right to bring up a set of controls and a list of all available slides
@@ -71,7 +71,7 @@ def define
task :all => [ 'tmp', output_dir, all_html, :remove_tmp ]
desc "Remove all generated output and temporary files"
- task :clean => "#{name}:remove_tmp" do
+ task :clean => "remove_tmp" do
FileUtils.rm_rf output_path
end
@@ -15,8 +15,9 @@ def teardown
end
def test_process
- assert !File.exist?(@output)
+ assert !File.exist?(@output), "#{@output} already exists"
@pressie.process(@input, @output)
+ puts @output.inspect
assert File.exist?(@output)
end
View
@@ -22,13 +22,12 @@ class Test::Unit::TestCase
private
- def generate
+ def generate
run_generator('codex', [Codex.root], sources)
end
def sources
- [RubiGen::PathSource.new(:test, File.join(File.dirname(__FILE__),"..", 'app_generators'))
- ]
+ [ RubiGen::PathSource.new(:test, File.join(File.dirname(__FILE__),"..", 'app_generators')) ]
end
end

0 comments on commit e7fa7b3

Please sign in to comment.