test/cli/commands/test_compile.rb in nanoc-3.7.3 vs test/cli/commands/test_compile.rb in nanoc-3.7.4

- old
+ new

@@ -116,20 +116,20 @@ end def test_setup_and_teardown_listeners with_site do test_listener_class = Class.new(::Nanoc::CLI::Commands::Compile::Listener) do - def start ; @started = true ; end - def stop ; @stopped = true ; end - def started? ; @started ; end - def stopped? ; @stopped ; end + def start; @started = true; end + def stop; @stopped = true; end + def started?; @started; end + def stopped?; @stopped; end end options = {} arguments = [] cmd = nil - listener_classes = [ test_listener_class ] + listener_classes = [test_listener_class] cmd_runner = Nanoc::CLI::Commands::Compile.new( options, arguments, cmd, :listener_classes => listener_classes) cmd_runner.run @@ -146,11 +146,11 @@ rep = Nanoc::ItemRep.new(item, :default) rep.raw_path = 'output/foo.txt' rep.compiled = true # Listen - listener = new_file_action_printer([ rep ]) + listener = new_file_action_printer([rep]) listener.start Nanoc::NotificationCenter.post(:compilation_started, rep) Nanoc::NotificationCenter.post(:rep_written, rep, rep.raw_path, false, true) listener.stop @@ -167,10 +167,10 @@ item = Nanoc::Item.new('content', {}, '/') rep = Nanoc::ItemRep.new(item, :default) rep.raw_path = 'output/foo.txt' # Listen - listener = new_file_action_printer([ rep ]) + listener = new_file_action_printer([rep]) listener.start Nanoc::NotificationCenter.post(:compilation_started, rep) listener.stop # Check