2014-03-12 11:31:40 -04:00
|
|
|
require "minitest/autorun"
|
|
|
|
require "fog/brightbox"
|
|
|
|
|
2014-04-03 04:35:26 -04:00
|
|
|
describe Fog::Compute::Brightbox do
|
|
|
|
before do
|
2014-03-13 06:30:35 -04:00
|
|
|
@arguments = {
|
|
|
|
:brightbox_auth_url => "http://localhost",
|
|
|
|
:brightbox_api_url => "http://localhost",
|
|
|
|
:brightbox_client_id => "",
|
|
|
|
:brightbox_secret => "",
|
|
|
|
:brightbox_username => "",
|
|
|
|
:brightbox_password => "",
|
|
|
|
:brightbox_account => ""
|
|
|
|
}
|
|
|
|
|
|
|
|
@credential_guard = Minitest::Mock.new
|
|
|
|
def @credential_guard.reject
|
|
|
|
{}
|
|
|
|
end
|
|
|
|
|
|
|
|
Fog.stub :credentials, @credential_guard do
|
|
|
|
@service = Fog::Compute::Brightbox.new(@arguments)
|
|
|
|
end
|
2014-03-12 11:31:40 -04:00
|
|
|
end
|
|
|
|
|
2014-04-03 04:35:26 -04:00
|
|
|
it "responds to #request" do
|
2014-03-12 11:31:40 -04:00
|
|
|
assert_respond_to @service, :request
|
|
|
|
end
|
|
|
|
|
2014-04-03 04:35:26 -04:00
|
|
|
it "responds to #request_access_token" do
|
2014-03-12 11:31:40 -04:00
|
|
|
assert_respond_to @service, :request_access_token
|
|
|
|
end
|
|
|
|
|
2014-04-03 04:35:26 -04:00
|
|
|
it "responds to #wrapped_request" do
|
2014-03-12 11:31:40 -04:00
|
|
|
assert_respond_to @service, :wrapped_request
|
|
|
|
end
|
|
|
|
end
|