From 3b0f9f50a20a820939276ea5b23e4c7dfa9ab2bb Mon Sep 17 00:00:00 2001 From: Sergio Rubio Date: Tue, 5 Mar 2013 18:59:46 +0100 Subject: [PATCH] [openstack|storage] added missing mocks --- lib/fog/openstack/storage.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lib/fog/openstack/storage.rb b/lib/fog/openstack/storage.rb index 6ab3246b4..0b800f631 100644 --- a/lib/fog/openstack/storage.rb +++ b/lib/fog/openstack/storage.rb @@ -48,6 +48,7 @@ module Fog require 'mime/types' @openstack_api_key = options[:openstack_api_key] @openstack_username = options[:openstack_username] + @path = '/v1/AUTH_1234' end def data @@ -57,6 +58,16 @@ module Fog def reset_data self.class.data.delete(@openstack_username) end + + def change_account(account) + @original_path ||= @path + version_string = @original_path.split('/')[1] + @path = "/#{version_string}/#{account}" + end + + def reset_account_name + @path = @original_path + end end