Skip to content

Commit

Permalink
Update coerced_tests.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
aidanharan committed Aug 13, 2024
1 parent f1806a4 commit 1baa093
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions test/cases/coerced_tests.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2419,7 +2419,9 @@ class QueryLogsTest < ActiveRecord::TestCase
# SQL requires double single-quotes.
coerce_tests! :test_sql_commenter_format
def test_sql_commenter_format_coerced
ActiveRecord::QueryLogs.update_formatter(:sqlcommenter)
ActiveRecord::QueryLogs.tags_formatter = :sqlcommenter
ActiveRecord::QueryLogs.tags = [:application]

assert_queries_match(%r{/\*application=''active_record''\*/}) do
Dashboard.first
end
Expand All @@ -2428,7 +2430,7 @@ def test_sql_commenter_format_coerced
# SQL requires double single-quotes.
coerce_tests! :test_sqlcommenter_format_value
def test_sqlcommenter_format_value_coerced
ActiveRecord::QueryLogs.update_formatter(:sqlcommenter)
ActiveRecord::QueryLogs.tags_formatter = :sqlcommenter

ActiveRecord::QueryLogs.tags = [
:application,
Expand All @@ -2443,7 +2445,7 @@ def test_sqlcommenter_format_value_coerced
# SQL requires double single-quotes.
coerce_tests! :test_sqlcommenter_format_value_string_coercible
def test_sqlcommenter_format_value_string_coercible_coerced
ActiveRecord::QueryLogs.update_formatter(:sqlcommenter)
ActiveRecord::QueryLogs.tags_formatter = :sqlcommenter

ActiveRecord::QueryLogs.tags = [
:application,
Expand All @@ -2458,7 +2460,7 @@ def test_sqlcommenter_format_value_string_coercible_coerced
# SQL requires double single-quotes.
coerce_tests! :test_sqlcommenter_format_allows_string_keys
def test_sqlcommenter_format_allows_string_keys_coerced
ActiveRecord::QueryLogs.update_formatter(:sqlcommenter)
ActiveRecord::QueryLogs.tags_formatter = :sqlcommenter

ActiveRecord::QueryLogs.tags = [
:application,
Expand Down

0 comments on commit 1baa093

Please sign in to comment.