Sha256: 94a02dbb7267defca65b990ba203a8dceab2f5ce6721e31fd8e995ee78d1615c

Contents?: true

Size: 707 Bytes

Versions: 35

Compression:

Stored size: 707 Bytes

Contents

require 'spec_helper'

module Spree
  describe Api::ConfigController do
    render_views

    before do
      stub_authentication!
    end

    it "returns Spree::Money settings" do
      api_get :money
      response.should be_success
      json_response["symbol"].should == "$"
      json_response["symbol_position"].should == "before"
      json_response["no_cents"].should == false
      json_response["decimal_mark"].should == "."
      json_response["thousands_separator"].should == ","
    end

    it "returns some configuration settings" do
      api_get :show
      response.should be_success
      json_response["default_country_id"].should == Spree::Config[:default_country_id]
    end
  end
end

Version data entries

35 entries across 35 versions & 1 rubygems

Version Path
spree_api-2.2.14 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.13 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.12 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.11 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.10 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.9 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.1.12 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.8 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.1.11 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.7 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.1.10 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.4.0.rc2 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.4.0.rc1 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.3.4 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.1.9 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.6 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.3.3 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.3.2 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.2.5 spec/controllers/spree/api/config_controller_spec.rb
spree_api-2.1.8 spec/controllers/spree/api/config_controller_spec.rb