Sha256: ad101d9a19d839cd8983e749209c0d37ee98f29f31d26c8000826541bfd0dab0

Contents?: true

Size: 779 Bytes

Versions: 1

Compression:

Stored size: 779 Bytes

Contents

# frozen_string_literal: true
require 'spec_helper'

RSpec.describe FreshdeskApiclient do
  it('has a version number') { expect(FreshdeskApiclient::VERSION).not_to be nil }

  before { FreshdeskApiclient.domain = :domain }
  it('allows to set domain') { expect(FreshdeskApiclient.domain).to eq(:domain) }

  before { FreshdeskApiclient.username_or_api_key = :u }
  it('allows to set username_or_api_key') { expect(FreshdeskApiclient.username_or_api_key).to eq(:u) }

  before { FreshdeskApiclient.password = :p }
  it('allows to set password') { expect(FreshdeskApiclient.password).to eq(:p) }

  context 'when password was not set' do
    before { FreshdeskApiclient.password = nil }
    it('has a default password') { expect(FreshdeskApiclient.password).to eq('X') }
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
freshdesk_apiclient-0.1.3 spec/freshdesk_apiclient_spec.rb