Permalink
Browse files

Support for wrapping sequel examples in Transaction and Rollback for …

…speedy specs.
  • Loading branch information...
1 parent 8a802d3 commit 740f28b86214996e4ba2236c7efd39cd062f0a3a @pk committed May 8, 2009
Showing with 5 additions and 0 deletions.
  1. +5 −0 lib/merb_sequel/rspec/sequel.rb
@@ -0,0 +1,5 @@
+class Spec::Example::ExampleGroup
+ def execute(*args, &block)
+ Sequel::Model.db.transaction{super(*args, &block); raise Sequel::Error::Rollback}
+ end
+end

0 comments on commit 740f28b

Please sign in to comment.