spec/unit/embargoable_spec.rb in hydra-access-controls-12.0.0 vs spec/unit/embargoable_spec.rb in hydra-access-controls-12.0.1

- old
+ new

@@ -81,12 +81,12 @@ subject { model.lease_indexer_class } it { is_expected.to eq Hydra::AccessControls::LeaseIndexer } end describe 'validations' do - context "with dates" do + context "with past dates" do subject { ModsAsset.new(lease_expiration_date: past_date, embargo_release_date: past_date) } - it "validates embargo_release_date and lease_expiration_date" do + it "validates embargo_release_date and lease_expiration_date on create" do expect(subject).to_not be_valid expect(subject.errors[:lease_expiration_date]).to eq ['Must be a future date'] expect(subject.errors[:embargo_release_date]).to eq ['Must be a future date'] end end