Sha256: 429eada7c68bdc9af22e8e7d4587e6062765105e16bb13f8e949683c6b7fb701
Contents?: true
Size: 857 Bytes
Versions: 13
Compression:
Stored size: 857 Bytes
Contents
require 'conjur/authn' require 'conjur/config' describe Conjur::Authn do describe "netrc" do before { Conjur::Authn.instance_variable_set("@netrc", nil) Conjur::Config.should_receive(:[]).with(:netrc_path).and_return path } after { Conjur::Authn.instance_variable_set("@netrc", nil) } context "with specified netrc_path" do let(:path) { double("path") } it "consults Conjur::Config for netrc_path" do Netrc.should_receive(:read).with(path).and_return netrc = double("netrc") Conjur::Authn.netrc.should == netrc end end context "without specified netrc_path" do let(:path) { nil } it "uses default netrc path" do Netrc.should_receive(:read).with().and_return netrc = double("netrc") Conjur::Authn.netrc.should == netrc end end end end
Version data entries
13 entries across 13 versions & 1 rubygems