Sha256: 10ed7fbc8031c58133e62c62ce350fb7e23810384fa64a07df84efe787f564ff
Contents?: true
Size: 749 Bytes
Versions: 18
Compression:
Stored size: 749 Bytes
Contents
class StubDatabase < OpenStruct def provisioned? status == 'provisioned' end end Fabricator(:database, from: :stub_database) do transient :service type 'postgresql' handle do |attrs| Fabricate.sequence(:database) { |i| "#{attrs[:type]}-#{i}" } end passphrase 'password' status 'provisioned' connection_url 'postgresql://aptible:password@10.252.1.125:49158/db' account database_image disk { Fabricate(:database_disk) } service { nil } backups { [] } database_credentials { [] } created_at { Time.now } after_create do |database, transients| database.account.databases << database database.service = transients[:service] || Fabricate( :service, app: nil, database: database ) end end
Version data entries
18 entries across 18 versions & 1 rubygems