mirror of
https://github.com/inspec/inspec
synced 2025-01-26 11:55:44 +00:00
2a1b1d8e88
Signed-off-by: Miah Johnson <miah@chia-pet.org>
27 lines
580 B
Ruby
27 lines
580 B
Ruby
require 'helper'
|
|
|
|
describe Fetchers::Local do
|
|
let(:fetcher) { Fetchers::Local }
|
|
|
|
it 'registers with the fetchers registry' do
|
|
reg = Inspec::Fetcher.registry
|
|
_(reg['local']).must_equal fetcher
|
|
end
|
|
|
|
describe 'applied to this file' do
|
|
let(:res) { fetcher.resolve(__FILE__) }
|
|
|
|
it 'must be resolved' do
|
|
_(res).must_be_kind_of fetcher
|
|
end
|
|
end
|
|
|
|
describe 'applied to this folder' do
|
|
let(:path) { File.dirname(__FILE__) }
|
|
let(:res) { fetcher.resolve(path) }
|
|
|
|
it 'must be resolved' do
|
|
_(res).must_be_kind_of fetcher
|
|
end
|
|
end
|
|
end
|