Sha256: a8bcb280779d7fa5a79ddbdbdb796d06681d248c6a55bb0d33f5508dc519ee69
Contents?: true
Size: 1.05 KB
Versions: 8
Compression:
Stored size: 1.05 KB
Contents
require 'spec_helper' describe Mashery::Config do it "should raise an error on lack of key" do expect { Mashery::Config.new("spec/fixtures/config.no_key.yml") }.to raise_error(Mashery::ParamMissing, /key/) end it "should raise an error on lack of site_id" do expect { Mashery::Config.new("spec/fixtures/config.no_site_id.yml") }.to raise_error(Mashery::ParamMissing, /site_id/) end it "should raise an error on lack of secret" do expect { Mashery::Config.new("spec/fixtures/config.no_secret.yml") }.to raise_error(Mashery::ParamMissing, /secret/) end it "should raise an error on lack of host" do expect { Mashery::Config.new("spec/fixtures/config.no_host.yml") }.to raise_error(Mashery::ParamMissing, /host/) end it "should have site_id, key, secret, host and signature as attributes" do config = Mashery::Config.new("spec/fixtures/config.yml") expect do config.key config.secret config.signature config.host config.site_id end.to_not raise_error end end
Version data entries
8 entries across 8 versions & 1 rubygems