Sha256: ee2dd53579efdc6e8edf3d8991942ec1d51b6ef08259be6b6c1d8fc75a3bbd2b

Contents?: true

Size: 619 Bytes

Versions: 4

Compression:

Stored size: 619 Bytes

Contents

require "active_record"

I18n.enforce_available_locales = true

ActiveRecord::Base.establish_connection(
  adapter: "sqlite3",
  database: File.expand_path("test_app/db/db.sqlite", File.dirname(__FILE__)),
  verbosity: "quiet"
)

class TestMigration < ActiveRecord::Migration
  def self.up
    create_table :posts, force: true do |t|
      t.column :title, :string
      t.column :image_id, :string
      t.column :document_id, :string
      t.column :document_filename, :string
      t.column :document_content_type, :string
      t.column :document_size, :integer
    end
  end
end

quietly do
  TestMigration.up
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
refile-0.5.5 spec/refile/active_record_helper.rb
refile-0.5.4 spec/refile/active_record_helper.rb
refile-0.5.3 spec/refile/active_record_helper.rb
refile-0.5.2 spec/refile/active_record_helper.rb