Skip to content

Commit

Permalink
Fix specs that use certificates and private keys
Browse files Browse the repository at this point in the history
At some point recently, something changed on Travis-CI such that the specs
can no longer read these files using a relative file path. Changing these
to use the absolute path works fabulously.
  • Loading branch information
tjarratt committed May 24, 2015
1 parent b5b6e47 commit f2ce530
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions spec/savon/builder_spec.rb
Expand Up @@ -83,10 +83,21 @@
end

describe "#wsse_signature" do
let(:private_key) { "spec/fixtures/ssl/client_key.pem" }
let(:cert) { "spec/fixtures/ssl/client_cert.pem" }
let(:signature) { Akami::WSSE::Signature.new(Akami::WSSE::Certs.new(:cert_file => cert, :private_key_file => private_key))}
let(:globals) { Savon::GlobalOptions.new(wsse_signature: signature) }
let(:private_key) do
File.join(File.dirname(__FILE__), "spec/fixtures/ssl/client_key.pem")
end
let(:cert) do
File.join(File.dirname(__FILE__), "spec/fixtures/ssl/client_cert.pem")
end
let(:signature) do
Akami::WSSE::Signature.new(
Akami::WSSE::Certs.new(
:cert_file => cert,
:private_key_file => private_key
)
)
end
let(:globals) { Savon::GlobalOptions.new(wsse_signature: signature) }

subject(:signed_message_nn) {Nokogiri::XML(builder.to_s).remove_namespaces!}
subject(:signed_message) {Nokogiri::XML(builder.to_s)}
Expand Down

0 comments on commit f2ce530

Please sign in to comment.