test/cli/commands/test_prune.rb in nanoc-4.7.5 vs test/cli/commands/test_prune.rb in nanoc-4.7.6

- old
+ new

@@ -13,11 +13,11 @@ # Create output files File.open('output2/foo.html', 'w') { |io| io.write 'this is a foo.' } File.open('output2/index.html', 'w') { |io| io.write 'this is a index.' } assert_raises SystemExit do - Nanoc::CLI.run %w(prune) + Nanoc::CLI.run %w[prune] end assert File.file?('output2/index.html') assert File.file?('output2/foo.html') end @@ -41,11 +41,11 @@ # Create output files File.open('output2/foo.html', 'w') { |io| io.write 'this is a foo.' } File.open('output2/index.html', 'w') { |io| io.write 'this is a index.' } - Nanoc::CLI.run %w(prune --yes) + Nanoc::CLI.run %w[prune --yes] assert File.file?('output2/index.html') assert !File.file?('output2/foo.html') end end @@ -61,11 +61,11 @@ # Create output files File.open('output2/foo.html', 'w') { |io| io.write 'this is a foo.' } File.open('output2/index.html', 'w') { |io| io.write 'this is a index.' } - Nanoc::CLI.run %w(prune --dry-run) + Nanoc::CLI.run %w[prune --dry-run] assert File.file?('output2/index.html') assert File.file?('output2/foo.html') end end @@ -94,11 +94,11 @@ File.open('output/good-dir/blah', 'w') { |io| io.write 'stuff' } File.open('output/bad-file.html', 'w') { |io| io.write 'stuff' } File.open('output/bad-dir/blah', 'w') { |io| io.write 'stuff' } File.open('output/index.html', 'w') { |io| io.write 'stuff' } - Nanoc::CLI.run %w(prune --yes) + Nanoc::CLI.run %w[prune --yes] assert File.file?('output/index.html') assert File.file?('output/good-dir/blah') assert File.file?('output/good-file.html') assert !File.file?('output/bad-dir/blah') @@ -124,11 +124,11 @@ # Create output files FileUtils.mkdir_p('output-real/some-dir') File.open('output-real/some-file.html', 'w') { |io| io.write 'stuff' } File.open('output-real/index.html', 'w') { |io| io.write 'stuff' } - Nanoc::CLI.run %w(prune --yes) + Nanoc::CLI.run %w[prune --yes] assert File.file?('output-real/index.html') assert !File.directory?('output-real/some-dir') assert !File.file?('output-real/some-file.html') end @@ -142,10 +142,10 @@ # Create output files FileUtils.mkdir_p('output/a/b/c') File.open('output/a/b/c/index.html', 'w') { |io| io.write 'stuff' } - Nanoc::CLI.run %w(prune --yes) + Nanoc::CLI.run %w[prune --yes] assert !File.file?('output/a/b/c/index.html') assert !File.directory?('output/a/b/c') assert !File.directory?('output/a/b') assert !File.directory?('output/a')