Sha256: 39d4fafb9df95c469c4c369066ae838529ca729f066a3a90b7fcc0e89df10b5a

Contents?: true

Size: 273 Bytes

Versions: 31

Compression:

Stored size: 273 Bytes

Contents

require 'rails_helper'

RSpec.describe Locatable, type: :model do

  it "validates the locatable type" do
    l = Locatable.make(locatable: User.make)
    l.valid?.should == false
    l.errors.messages.should == {:locatable_type=>["is not included in the list"]}
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
introspective_grape-0.6.1 spec/models/locatable_spec.rb
introspective_grape-0.5.7 spec/models/locatable_spec.rb
introspective_grape-0.5.6 spec/models/locatable_spec.rb
introspective_grape-0.5.5 spec/models/locatable_spec.rb
introspective_grape-0.5.4 spec/models/locatable_spec.rb
introspective_grape-0.5.2 spec/models/locatable_spec.rb
introspective_grape-0.5.0 spec/models/locatable_spec.rb
introspective_grape-0.4.3 spec/models/locatable_spec.rb
introspective_grape-0.4.2 spec/models/locatable_spec.rb
introspective_grape-0.4.1 spec/models/locatable_spec.rb
introspective_grape-0.4.0 spec/models/locatable_spec.rb
introspective_grape-0.3.9 spec/models/locatable_spec.rb
introspective_grape-0.3.7 spec/models/locatable_spec.rb
introspective_grape-0.3.6 spec/models/locatable_spec.rb
introspective_grape-0.3.5 spec/models/locatable_spec.rb
introspective_grape-0.3.3 spec/models/locatable_spec.rb
introspective_grape-0.3.2 spec/models/locatable_spec.rb
introspective_grape-0.3.1 spec/models/locatable_spec.rb
introspective_grape-0.3.0 spec/models/locatable_spec.rb
introspective_grape-0.2.9 spec/models/locatable_spec.rb