Sha256: 75014e484058903417817c5bbd4e9916af8c7cbd7763ada4c06f36ee365f0aa8

Contents?: true

Size: 586 Bytes

Versions: 13

Compression:

Stored size: 586 Bytes

Contents

# frozen_string_literal: true

require 'spec_helper'

describe Sinclair::Model do
  describe 'readme' do
    it 'Simple usage' do
      human1 = Human.new(name: 'John Doe', age: 22)
      human2 = Human.new(name: 'John Doe', age: 22)

      expect(human1.name).to eq('John Doe')
      expect(human1.age).to eq(22)
      expect(human1.gender).to eq(:undefined)
      expect(human1 == human2).to eq(true)
    end

    it 'Without comparable' do
      tv1 = Tv.new(model: 'Sans Sunga Xt')
      tv2 = Tv.new(model: 'Sans Sunga Xt')

      expect(tv1 == tv2).to eq(false)
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
sinclair-2.1.1 spec/integration/readme/sinclair/model_spec.rb
sinclair-2.1.0 spec/integration/readme/sinclair/model_spec.rb
sinclair-2.0.1 spec/integration/readme/sinclair/model_spec.rb
sinclair-2.0.0 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.16.3 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.16.2 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.16.1 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.16.0 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.15.0 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.14.2 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.14.1 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.14.0 spec/integration/readme/sinclair/model_spec.rb
sinclair-1.13.0 spec/integration/readme/sinclair/model_spec.rb