Sha256: f3ecefe8dbe8f6a3a9c7cd00974f01895850987b8f5a520da134ff502d96bbd1

Contents?: true

Size: 757 Bytes

Versions: 1

Compression:

Stored size: 757 Bytes

Contents

#encoding: utf-8
require 'spec_helper'

describe Comfan do
  subject{Comfan}

  describe '.api_id' do
    it 'returns the same ID for API ID' do
      input = '752S00000000KtkIAE'
      expect(subject.api_id(input)).to eq(input)
    end

    it 'returns the correct API ID for UI ID' do
      input = '752S00000000Ktk'
      output = '752S00000000KtkIAE'
      expect(subject.api_id(input)).to eq(output)
    end
  end

  describe '.ui_id' do
    it 'returns the same ID for UI ID' do
      input = '752S00000000Ktk'
      expect(subject.ui_id(input)).to eq(input)
    end

    it 'returns the correct UI ID for API ID' do
      input = '752S00000000KtkIAE'
      output = '752S00000000Ktk'
      expect(subject.ui_id(input)).to eq(output)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
comfan-0.1.0 spec/lib/comfan_spec.rb