Sha256: 1731549263fafcd0b02fa18914826a25fc7bba8d5f30127c6adc8b6201d8f89c
Contents?: true
Size: 1.06 KB
Versions: 26
Compression:
Stored size: 1.06 KB
Contents
require 'spec_helper' RSpec.describe Spree::Core::StockConfiguration do describe '#coordinator_class' do let(:stock_configuration) { described_class.new } subject { stock_configuration.coordinator_class } it "returns Spree::Stock::Coordinator" do is_expected.to be ::Spree::Stock::Coordinator end context "with another constant name assiged" do MyCoordinator = Class.new before { stock_configuration.coordinator_class = MyCoordinator.to_s } it "returns the constant" do is_expected.to be MyCoordinator end end end describe '#estimator_class' do let(:stock_configuration) { described_class.new } subject { stock_configuration.estimator_class } it "returns Spree::Stock::Estimator" do is_expected.to be ::Spree::Stock::Estimator end context "with another constant name assiged" do MyEstimator = Class.new before { stock_configuration.estimator_class = MyEstimator.to_s } it "returns the constant" do is_expected.to be MyEstimator end end end end
Version data entries
26 entries across 26 versions & 1 rubygems