Sha256: 5ebb615dd9ed180c07efed89df678c97c9005a0e671dd171063e244fd40f5d1d

Contents?: true

Size: 515 Bytes

Versions: 6

Compression:

Stored size: 515 Bytes

Contents

require "active_record"
require "yaml"
require "stackflame"

Stackflame.profile do
  ActiveRecord::Base.configurations["profile"] = {
    adapter: "sqlite3",
    database: "test.sqlite3",
    pool: 5,
    timeout: 5000,
  }
  ActiveRecord::Base.establish_connection :profile

  ActiveRecord::Schema.define do
    create_table :users, force: true do |t|
      t.column :created_at, :datetime
      t.column :updated_at, :datetime
    end
  end

  class User < ActiveRecord::Base; end
  100.times { User.create }
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
stackflame-0.2.5 example/ar_profile.rb
stackflame-0.2.4 example/ar_profile.rb
stackflame-0.2.1 example/ar_profile.rb
stackflame-0.2.0 example/ar_profile.rb
stackflame-0.1.0 example/ar_profile.rb
stackflame-0.0.1 example/ar_profile.rb