Sha256: 2beb42c788dab23dd19f5297532b74956e41eaf01b06bb55b02d79e3dfaf77d6

Contents?: true

Size: 815 Bytes

Versions: 2

Compression:

Stored size: 815 Bytes

Contents

require File.expand_path('../spec_helper', __FILE__)

WHITELIST_PATH = './spec/mocks/whitelist.json'

describe WhitelistResolver do
    describe 'functionality' do
        it 'whitelist should be loaded from an specific url' do
            whitelist = WhitelistResolver.instance.get_whitelist(WHITELIST_PATH)
            whitelist.size.should.equal 11
        end
        
        it 'if not URL is specified, whitelist comes from default URL' do
            whitelist = WhitelistResolver.instance.get_whitelist
            whitelist.should.not.empty?
        end

        it 'whitelist should not be loaded twice' do
            WhitelistResolver.instance.get_whitelist(WHITELIST_PATH)
            loaded = WhitelistResolver.instance.whitelist_loaded

            loaded.should.be.true    
        end
    end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
cocoapods-whitelist-0.5.5 spec/whitelist_resolver_spec.rb
cocoapods-whitelist-0.5.4 spec/whitelist_resolver_spec.rb