aboutsummaryrefslogtreecommitdiffstats
path: root/spec/models/event_spec.rb
blob: adf288afb29256a620370e827940019712efa578 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
require 'rails_helper'

RSpec.describe Event, type: :model do
  it "is invalid without a name" do 
    e = Event.new(name: "")
    expect(e).to_not be_valid
  end

  describe "validations" do
    it "is invalid without a date" do
      e = Event.new(date: nil, name: "Sludge")
      expect(e).to_not be_valid
    end
  end
end