We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5d30181 commit cef7c28Copy full SHA for cef7c28
test/cases/coerced_tests.rb
@@ -254,6 +254,14 @@ class DatabaseTasksDropAllTest < ActiveRecord::TestCase
254
class DefaultScopingTest < ActiveRecord::TestCase
255
# We are not doing order duplicate removal anymore.
256
coerce_tests! :test_order_in_default_scope_should_not_prevail
257
+
258
+ # Use our escaped format in assertion.
259
+ coerce_tests! :test_with_abstract_class_scope_should_be_executed_in_correct_context
260
+ def test_with_abstract_class_scope_should_be_executed_in_correct_context_coerced
261
+ vegetarian_pattern, gender_pattern = [/[lions].[is_vegetarian]/, /[lions].[gender]/]
262
+ assert_match vegetarian_pattern, Lion.all.to_sql
263
+ assert_match gender_pattern, Lion.female.to_sql
264
+ end
265
end
266
267
0 commit comments