[Groonga-commit] droonga/drntest at 2079d74 [master] Fix collision of variable names

Back to archive index

YUKI Hiroshi null+****@clear*****
Wed Nov 27 10:58:33 JST 2013


YUKI Hiroshi	2013-11-27 10:58:33 +0900 (Wed, 27 Nov 2013)

  New Revision: 2079d74b2422b99b10ab1e42836861cf4d697cc7
  https://github.com/droonga/drntest/commit/2079d74b2422b99b10ab1e42836861cf4d697cc7

  Message:
    Fix collision of variable names

  Modified files:
    lib/drntest/test-runner.rb

  Modified: lib/drntest/test-runner.rb (+6 -6)
===================================================================
--- lib/drntest/test-runner.rb    2013-11-27 10:57:50 +0900 (6900fab)
+++ lib/drntest/test-runner.rb    2013-11-27 10:58:33 +0900 (fa6bb9b)
@@ -205,7 +205,7 @@ module Drntest
     DIRECTIVE_MATCHER = /\A\#\@([^\s]+)(?:\s+(.+))?\n?\z/.freeze
 
     def load_options(path, options={})
-      options = {}
+      loaded_options = {}
       Pathname(path).read.each_line do |line|
         next unless DIRECTIVE_MATCHER =~ line
         key = $1.gsub(/-/, "_").to_sym
@@ -216,15 +216,15 @@ module Drntest
           included_options = load_options(included,
                                           options.merge(:base_path => included))
           included_options.each do |key, values|
-            options[key] ||= []
-            options[key] += values
+            loaded_options[key] ||= []
+            loaded_options[key] += values
           end
         else
-          options[key] ||= []
-          options[key] << value
+          loaded_options[key] ||= []
+          loaded_options[key] << value
         end
       end
-      options
+      loaded_options
     end
 
     def load_request_envelopes
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index