Sha256: 536bedaa99ca7bab66049d1a744b91e4e6e4df2bdf33122f3f6ff4e9232c860f

Contents?: true

Size: 880 Bytes

Versions: 19

Compression:

Stored size: 880 Bytes

Contents

# frozen_string_literal: true

require 'spec_helper'

describe BudgeaClient::Configuration do
  let(:config) { BudgeaClient::Configuration.default }

  before(:each) do
    # uncomment below to setup host and base_path
    #require 'URI'
    #uri = URI.parse("https://demo.biapi.pro/2.0/")
    #BudgeaClient.configure do |c|
    #  c.host = uri.host
    #  c.base_path = uri.path
    #end
  end

  describe '#base_url' do
    it 'should have the default value' do
      # uncomment below to test default value of the base path
      #expect(config.base_url).to eq("https://demo.biapi.pro/2.0/")
    end

    it 'should remove trailing slashes' do
      [nil, '', '/', '//'].each do |base_path|
        config.base_path = base_path
        # uncomment below to test trailing slashes
        #expect(config.base_url).to eq("https://demo.biapi.pro/2.0/")
      end
    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
budgea_client-3.0.1 spec/configuration_spec.rb
budgea_client-3.0.0 spec/configuration_spec.rb
budgea_client-2.0.2 spec/configuration_spec.rb
budgea_client-2.0.1 spec/configuration_spec.rb
budgea_client-2.0.0 spec/configuration_spec.rb
budgea_client-1.4.4 spec/configuration_spec.rb
budgea_client-1.4.3 spec/configuration_spec.rb
budgea_client-1.4.2 spec/configuration_spec.rb
budgea_client-1.3.9 spec/configuration_spec.rb
budgea_client-1.3.6 spec/configuration_spec.rb
budgea_client-1.3.5 spec/configuration_spec.rb
budgea_client-1.3.4 spec/configuration_spec.rb
budgea_client-1.3.3 spec/configuration_spec.rb
budgea_client-1.3.2 spec/configuration_spec.rb
budgea_client-1.3.1 spec/configuration_spec.rb
budgea_client-1.3.0 spec/configuration_spec.rb
budgea_client-1.2.0 spec/configuration_spec.rb
budgea_client-1.1.0 spec/configuration_spec.rb
budgea_client-1.0.0 spec/configuration_spec.rb