From 34c9faa778de2a3238e984905efeb793762aafd9 Mon Sep 17 00:00:00 2001 From: Dan Barber Date: Tue, 4 Jun 2013 08:42:56 +0100 Subject: [PATCH] Add contact spec (not working) --- spec/models/contact_spec.rb | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 spec/models/contact_spec.rb diff --git a/spec/models/contact_spec.rb b/spec/models/contact_spec.rb new file mode 100644 index 0000000..fc5c2c6 --- /dev/null +++ b/spec/models/contact_spec.rb @@ -0,0 +1,9 @@ +require 'spec_helper' + +describe Contact do + it { should validate_presence_of(:email) } + it { should validate_presence_of(:name) } + it { should validate_presence_of(:message) } + + it { should allow_value("test@test.com").for(:email) } +end