mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Move this is Mock.key_id and don't default the path
This commit is contained in:
parent
c276ebdbe6
commit
70337bbc5b
2 changed files with 7 additions and 3 deletions
|
@ -224,7 +224,12 @@ module Fog
|
||||||
def self.volume_id
|
def self.volume_id
|
||||||
"vol-#{Fog::Mock.random_hex(8)}"
|
"vol-#{Fog::Mock.random_hex(8)}"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def self.key_id(length=21)
|
||||||
|
#Probably close enough
|
||||||
|
Fog::Mock.random_selection('ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789',length)
|
||||||
|
end
|
||||||
|
|
||||||
def self.rds_address(db_name,region)
|
def self.rds_address(db_name,region)
|
||||||
"#{db_name}.#{Fog::Mock.random_letters(rand(12) + 4)}.#{region}.rds.amazonaws.com"
|
"#{db_name}.#{Fog::Mock.random_letters(rand(12) + 4)}.#{region}.rds.amazonaws.com"
|
||||||
end
|
end
|
||||||
|
|
|
@ -64,8 +64,7 @@ module Fog
|
||||||
:server_certificates => {},
|
:server_certificates => {},
|
||||||
:users => Hash.new do |uhash, ukey|
|
:users => Hash.new do |uhash, ukey|
|
||||||
uhash[ukey] = {
|
uhash[ukey] = {
|
||||||
:user_id => Fog::Mock.random_selection('ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789', 21),
|
:user_id => Fog::AWS::Mock.key_id,
|
||||||
:path => '/',
|
|
||||||
:arn => "arn:aws:iam::#{Fog::AWS::Mock.owner_id}:user/#{ukey}",
|
:arn => "arn:aws:iam::#{Fog::AWS::Mock.owner_id}:user/#{ukey}",
|
||||||
:access_keys => [],
|
:access_keys => [],
|
||||||
:policies => {}
|
:policies => {}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue