describe Category, "not from fixture" do
before(:each) do
@category = Category.new
end
it "should not be valid if name and description are not given" do
@category.should_not be_valid
end
it "should change name value" do
lambda { @category.name = "Unterhaltung" }.should change(@category, :name)
end
it "should respond to :name" do
@category.should respond_to(:name)
end
it "should have the same name as given name" do
@category.name = "Unterhaltung"
@category.name.should == "Unterhaltung"
@category.name.should eql("Unterhaltung")
@category.name.should_not equal("Unterhaltung")
end