Sha256: e4c44bc51d84fa5dd41c062a9710f3f63b26ff68db4b20f70bc18c37b798e259
Contents?: true
Size: 642 Bytes
Versions: 5
Compression:
Stored size: 642 Bytes
Contents
require 'spec_helper' describe Spree::OptionValue, :type => :model do context "touching" do it "should touch a variant" do variant = create(:variant) option_value = variant.option_values.first variant.update_column(:updated_at, 1.day.ago) option_value.touch expect(variant.reload.updated_at).to be_within(3.seconds).of(Time.now) end end describe "#presentation_with_option_type" do let(:option_value) { build(:option_value) } subject { option_value.presentation_with_option_type } it "returns a string in the correct form" do expect(subject).to eq "Size - S" end end end
Version data entries
5 entries across 5 versions & 1 rubygems