Permalink
Browse files

Extra docs.

  • Loading branch information...
1 parent a6e88e0 commit 0c77db3414c1392a880cb4e639422c94889fa45c @pk committed May 8, 2009
Showing with 4 additions and 1 deletion.
  1. +4 −1 spec/spec_model.rb
View
5 spec/spec_model.rb
@@ -1,6 +1,8 @@
+# Dummy model for testing
class SpecModel < Sequel::Model
end
+# Migrations to create the table
class CreateSpecModel < Sequel::Migration
def up
create_table! :spec_models do
@@ -14,6 +16,7 @@ def down
end
end
+# Shared describe to run migration
describe "it has a SpecModel", :shared => true do
before(:each) do
CreateSpecModel.apply(SpecModel.db, :up)
@@ -22,4 +25,4 @@ def down
after(:each) do
CreateSpecModel.apply(SpecModel.db, :down)
end
-end
+end

0 comments on commit 0c77db3

Please sign in to comment.