Sha256: 6781104fa707ea1d6eb176e70706d2e793f2908e8d0fd9c57cdf4d65c8ce0b39
Contents?: true
Size: 895 Bytes
Versions: 1
Compression:
Stored size: 895 Bytes
Contents
ActiveRecord::Base.establish_connection( adapter: 'postgresql', database: 'granite', username: 'granite', password: 'granite', host: 'localhost' ) ActiveRecord::Base.logger = Logger.new('/dev/null') ActiveRecord::Schema.define do create_table :users, force: :cascade do |t| t.column :email, :string t.column :projects, :text t.column :profile, :text end create_table :authors, force: :cascade do |t| t.column :name, :string t.column :status, :integer t.column :related_ids, :integer, array: true t.column :data, :text end if ActiveModel.version >= Gem::Version.new('7.0.0') create_enum 'foo', %w[foo bar baz] create_table :foo_containers, force: :cascade do |t| t.enum :foos, enum_type: 'foo', array: true end end end if ActiveModel.version >= Gem::Version.new('7.0.0') class FooContainer < ActiveRecord::Base end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
granite-form-0.6.0 | spec/support/active_record.rb |