Add option to Class#class_attribute for skipping the query method
Add test for Class#class_attribute
Remove ActiveRecord#Base.default_scopes?

Fixes ##10107.