Sha256: 650c91f2d96631fa89760799771edd18f881a4a092911b78128cc1fb7ee1ab6c

Contents?: true

Size: 431 Bytes

Versions: 43

Compression:

Stored size: 431 Bytes

Contents

require 'spec_helper'

describe Spree::ProductProperty, type: :model do
  context "touching" do
    let(:product_property) { create(:product_property) }
    let(:product) { product_property.product }

    before do
      product.update_columns(updated_at: 1.day.ago)
    end

    subject { product_property.touch }

    it "touches the product" do
      expect { subject }.to change { product.reload.updated_at }
    end
  end
end

Version data entries

43 entries across 43 versions & 1 rubygems

Version Path
solidus_core-2.3.1 spec/models/spree/product_property_spec.rb
solidus_core-2.2.2 spec/models/spree/product_property_spec.rb
solidus_core-2.1.1 spec/models/spree/product_property_spec.rb
solidus_core-2.0.3 spec/models/spree/product_property_spec.rb
solidus_core-1.4.2 spec/models/spree/product_property_spec.rb
solidus_core-1.3.2 spec/models/spree/product_property_spec.rb
solidus_core-1.2.3 spec/models/spree/product_property_spec.rb
solidus_core-1.1.4 spec/models/spree/product_property_spec.rb
solidus_core-2.3.0 spec/models/spree/product_property_spec.rb
solidus_core-2.3.0.rc3 spec/models/spree/product_property_spec.rb
solidus_core-2.3.0.rc2 spec/models/spree/product_property_spec.rb
solidus_core-2.3.0.rc1 spec/models/spree/product_property_spec.rb
solidus_core-2.3.0.beta1 spec/models/spree/product_property_spec.rb
solidus_core-2.0.2 spec/models/spree/product_property_spec.rb
solidus_core-1.4.1 spec/models/spree/product_property_spec.rb
solidus_core-2.2.1 spec/models/spree/product_property_spec.rb
solidus_core-2.2.0 spec/models/spree/product_property_spec.rb
solidus_core-2.2.0.rc1 spec/models/spree/product_property_spec.rb
solidus_core-2.2.0.beta1 spec/models/spree/product_property_spec.rb
solidus_core-2.1.0 spec/models/spree/product_property_spec.rb