Files
openfoodnetwork/spec/models/spree/property_spec.rb

18 lines
469 B
Ruby

require 'spec_helper'
module Spree
describe Property do
describe "callbacks" do
let(:property) { product_property.property }
let(:product) { product_property.product }
let(:product_property) { create(:product_property) }
it "refreshes the products cache on save" do
expect(OpenFoodNetwork::ProductsCache).to receive(:product_changed).with(product)
property.name = 'asdf'
property.save
end
end
end
end