Skip to content

Instantly share code, notes, and snippets.

@jescalante
jescalante / sequel_model_without_a_table.rb
Created October 10, 2012 20:19
Trying to use a sequel model without a table
class Foo < Sequel::Model
plugin :timestamps, :create => :created_on, :update => :updated_on
plugin :validation_helpers
many_to_one :user
def initialize(params={}) ... end
def before_save ... end
@jescalante
jescalante / gist:1443155
Created December 7, 2011 15:13
Capybara relative links
# test_helper.rb
...
require 'capybara/rails'
require 'minitest/autorun'
Capybara.configure do |config|
config.run_server = true
config.server_port = 9887
config.app_host = 'http://www.example.com:9887'
end