Index: test/unit/version_test.rb
===================================================================
--- test/unit/version_test.rb	(revision 10805)
+++ test/unit/version_test.rb	(working copy)
@@ -32,7 +32,13 @@
 
   def test_invalid_effective_date_validation
     v = Version.new(:project => Project.find(1), :name => '1.1', :effective_date => '99999-01-01')
-    assert !v.save
+    assert !v.valid?
+    v.effective_date = '2012-11-33'
+    assert !v.valid?
+    v.effective_date = '2012-31-11'
+    assert !v.valid?
+    v.effective_date = 'ABC'
+    assert !v.valid?
     assert_include I18n.translate('activerecord.errors.messages.not_a_date'),
                    v.errors[:effective_date]
   end
Index: app/models/version.rb
===================================================================
--- app/models/version.rb	(revision 10805)
+++ app/models/version.rb	(working copy)
@@ -30,7 +30,7 @@
   validates_presence_of :name
   validates_uniqueness_of :name, :scope => [:project_id]
   validates_length_of :name, :maximum => 60
-  validates_format_of :effective_date, :with => /^\d{4}-\d{2}-\d{2}$/, :message => :not_a_date, :allow_nil => true
+  validate :validate_effective_date
   validates_inclusion_of :status, :in => VERSION_STATUSES
   validates_inclusion_of :sharing, :in => VERSION_SHARINGS
 
@@ -275,4 +275,12 @@
       progress
     end
   end
+
+  def validate_effective_date
+    unless effective_date_before_type_cast.empty? ||
+      ((effective_date_before_type_cast =~ /^\d{4}-\d{2}-\d{2}$/) &&
+        (begin; effective_date_before_type_cast.to_date; rescue; false end))
+      errors.add(:effective_date, :not_a_date)
+    end
+  end
 end
