aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoryuuji.yaginuma <yuuji.yaginuma@gmail.com>2017-09-21 13:33:43 +0900
committeryuuji.yaginuma <yuuji.yaginuma@gmail.com>2017-09-21 13:33:43 +0900
commit4883a82251d498388a7186367d251f2185faf4c3 (patch)
treee15ab263484cedabf32a68a6ddc0e26aebb19aaf
parent6c199967fc5c32155684b95628751eb1b5098e13 (diff)
downloadrails-4883a82251d498388a7186367d251f2185faf4c3.tar.gz
rails-4883a82251d498388a7186367d251f2185faf4c3.tar.bz2
rails-4883a82251d498388a7186367d251f2185faf4c3.zip
Fix "warning: `*' interpreted as argument prefix"
This fixes following warning: ``` /home/travis/build/rails/rails/activerecord/test/cases/instrumentation_test.rb:11: warning: `*' interpreted as argument prefix /home/travis/build/rails/rails/activerecord/test/cases/instrumentation_test.rb:23: warning: `*' interpreted as argument prefix /home/travis/build/rails/rails/activerecord/test/cases/instrumentation_test.rb:35: warning: `*' interpreted as argument prefix /home/travis/build/rails/rails/activerecord/test/cases/instrumentation_test.rb:48: warning: `*' interpreted as argument prefix /home/travis/build/rails/rails/activerecord/test/cases/instrumentation_test.rb:61: warning: `*' interpreted as argument prefix ```
-rw-r--r--activerecord/test/cases/instrumentation_test.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/activerecord/test/cases/instrumentation_test.rb b/activerecord/test/cases/instrumentation_test.rb
index 86ffe8b0d7..e6e8468757 100644
--- a/activerecord/test/cases/instrumentation_test.rb
+++ b/activerecord/test/cases/instrumentation_test.rb
@@ -8,7 +8,7 @@ module ActiveRecord
def test_payload_name_on_load
Book.create(name: "test book")
subscriber = ActiveSupport::Notifications.subscribe("sql.active_record") do |*args|
- event = ActiveSupport::Notifications::Event.new *args
+ event = ActiveSupport::Notifications::Event.new(*args)
if event.payload[:sql].match "SELECT"
assert_equal "Book Load", event.payload[:name]
end
@@ -20,7 +20,7 @@ module ActiveRecord
def test_payload_name_on_create
subscriber = ActiveSupport::Notifications.subscribe("sql.active_record") do |*args|
- event = ActiveSupport::Notifications::Event.new *args
+ event = ActiveSupport::Notifications::Event.new(*args)
if event.payload[:sql].match "INSERT"
assert_equal "Book Create", event.payload[:name]
end
@@ -32,7 +32,7 @@ module ActiveRecord
def test_payload_name_on_update
subscriber = ActiveSupport::Notifications.subscribe("sql.active_record") do |*args|
- event = ActiveSupport::Notifications::Event.new *args
+ event = ActiveSupport::Notifications::Event.new(*args)
if event.payload[:sql].match "UPDATE"
assert_equal "Book Update", event.payload[:name]
end
@@ -45,7 +45,7 @@ module ActiveRecord
def test_payload_name_on_update_all
subscriber = ActiveSupport::Notifications.subscribe("sql.active_record") do |*args|
- event = ActiveSupport::Notifications::Event.new *args
+ event = ActiveSupport::Notifications::Event.new(*args)
if event.payload[:sql].match "UPDATE"
assert_equal "Book Update All", event.payload[:name]
end
@@ -58,7 +58,7 @@ module ActiveRecord
def test_payload_name_on_destroy
subscriber = ActiveSupport::Notifications.subscribe("sql.active_record") do |*args|
- event = ActiveSupport::Notifications::Event.new *args
+ event = ActiveSupport::Notifications::Event.new(*args)
if event.payload[:sql].match "DELETE"
assert_equal "Book Destroy", event.payload[:name]
end