Skip to content

Commit

Permalink
add regression test for #24
Browse files Browse the repository at this point in the history
  • Loading branch information
radar committed Nov 15, 2012
1 parent 32d07ae commit 131cb29
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/paranoia_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,12 @@ def test_destroy_behavior_for_featureful_paranoid_models
assert_equal 1, model.class.unscoped.count
end

# Regression test for #24
def test_chaining_for_paranoid_models
scope = FeaturefulModel.where(:name => "foo").only_deleted
scope.where_values.count.should == 2
end

def test_only_destroyed_scope_for_paranoid_models
model = ParanoidModel.new
model.save
Expand Down

0 comments on commit 131cb29

Please sign in to comment.