test/cli/commands/test_compile.rb in nanoc-4.2.1 vs test/cli/commands/test_compile.rb in nanoc-4.2.2
- old
+ new
@@ -19,11 +19,11 @@
io.write "end\n"
io.write "\n"
io.write "layout '*', :erb\n"
end
- Nanoc::CLI.run %w( compile --verbose )
+ Nanoc::CLI.run %w(compile --verbose)
end
end
def test_auto_prune
with_site do |_site|
@@ -56,21 +56,21 @@
File.open('output/stray.html', 'w') do |io|
io.write 'I am a stray file and I am about to be deleted!'
end
assert File.file?('output/stray.html')
- Nanoc::CLI.run %w( compile )
+ Nanoc::CLI.run %w(compile)
assert File.file?('output/stray.html')
File.open('nanoc.yaml', 'w') do |io|
io.write "string_pattern_type: legacy\n"
io.write "prune:\n"
io.write " auto_prune: true\n"
end
assert File.file?('output/stray.html')
- Nanoc::CLI.run %w( compile )
+ Nanoc::CLI.run %w(compile)
refute File.file?('output/stray.html')
end
end
def test_auto_prune_with_exclude
@@ -106,22 +106,22 @@
File.open('output/stray.html', 'w') do |io|
io.write 'I am a stray file and I am about to be deleted!'
end
assert File.file?('output/stray.html')
- Nanoc::CLI.run %w( compile )
+ Nanoc::CLI.run %w(compile)
assert File.file?('output/stray.html')
File.open('nanoc.yaml', 'w') do |io|
io.write "string_pattern_type: legacy\n"
io.write "prune:\n"
io.write " auto_prune: true\n"
io.write " exclude: [ 'excluded_dir' ]\n"
end
assert File.file?('output/stray.html')
- Nanoc::CLI.run %w( compile )
+ Nanoc::CLI.run %w(compile)
refute File.file?('output/stray.html')
assert File.directory?('output/excluded_dir'), 'excluded_dir should still be there'
end
end
@@ -203,10 +203,10 @@
end
def new_file_action_printer(reps)
# Ensure CLI is loaded
begin
- Nanoc::CLI.run(%w( help %))
+ Nanoc::CLI.run(%w(help %))
rescue SystemExit
end
listener = Nanoc::CLI::Commands::Compile::FileActionPrinter.new(reps: reps)