test/test_helper.rb in parallel_minion-1.2.0 vs test/test_helper.rb in parallel_minion-1.2.1
- old
+ new
@@ -1,13 +1,14 @@
-$LOAD_PATH.unshift File.dirname(__FILE__) + '/../lib'
+#$LOAD_PATH.unshift File.dirname(__FILE__) + '/../lib'
require 'minitest/autorun'
require 'parallel_minion'
require 'semantic_logger'
SemanticLogger.default_level = :trace
SemanticLogger.add_appender(file_name: 'test.log', formatter: :color)
# Setup global callback for metric so that it can be tested below
+$log_structs = []
SemanticLogger.on_metric do |log_struct|
- ($log_structs ||= []) << log_struct.dup
+ $log_structs << log_struct.dup
end