remarkable/remarkable — Issue #35: Please, restore should_have_default_scope in rails-3.1 branch
Author: maksar
Created: 2011-11-17 22:58:20+00:00
State: open

Following code could be used to ensure, that default scope works as expected:

EmailLetter.scoped.to_sql.should == EmailLetter.unscoped.where(:sent => false, :error => false).to_sql

Usage would be:

it { should have_default_scope.where(:sent => false, :error => false) }

I'll provide pull request if needed.