Skip to content

Commit

Permalink
Adding spec for database setting
Browse files Browse the repository at this point in the history
  • Loading branch information
durran committed Dec 9, 2009
1 parent c235672 commit 1cd9694
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions spec/unit/mongoid_spec.rb
@@ -0,0 +1,17 @@
require "spec_helper"

describe Mongoid do

describe ".database=" do

context "when object provided is not a Mongo::DB" do

it "raises an error" do
lambda { Mongoid.database = "Test" }.should raise_error
end

end

end

end

0 comments on commit 1cd9694

Please sign in to comment.