aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord')
-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