Skip to content

Instantly share code, notes, and snippets.

# Activate the gem you are reporting the issue against.
require 'active_record'
require 'minitest/autorun'
require 'logger'
# Ensure backward compatibility with Minitest 4
Minitest::Test = MiniTest::Unit::TestCase unless defined?(Minitest::Test)
# This connection will do for database-independent bug reports.
ActiveRecord::Base.establish_connection(adapter: 'postgresql', database: 'test123')
require 'bundler'
Bundler.setup(:default)
require 'active_record'
require 'minitest/autorun'
require 'logger'
# This connection will do for database-independent bug reports.
ActiveRecord::Base.establish_connection(adapter: 'sqlite3', database: ':memory:')
ActiveRecord::Base.logger = Logger.new(STDOUT)
guides :: (nateberkopec-make_guides_html_valid) » bundle exec rake guides:validate ~/Projects/rails/guides 1 ↵
/Users/senny/.rbenv/versions/2.0.0-p451/bin/ruby w3c_validator.rb
EEEEEEEEEEEEEEEEEEEEEEEEEEE
Could not validate ./output/debugging_rails_applications.html because of 502 "Proxy Error"
EEEEEEEEE
Could not validate ./output/maintenance_policy.html because of 502 "Proxy Error"
E
Could not validate ./output/nested_model_forms.html because of 502 "Proxy Error"
E
Could not validate ./output/rails_application_templates.html because of 502 "Proxy Error"
@senny
senny / test.rb
Last active August 29, 2015 14:01
require 'bundler'
Bundler.setup(:default)
require 'active_record'
require 'minitest/autorun'
require 'logger'
# This connection will do for database-independent bug reports.
ActiveRecord::Base.establish_connection(adapter: 'sqlite3', database: ':memory:')
ActiveRecord::Base.logger = Logger.new(STDOUT)
require 'bundler'
Bundler.setup(:default)
require 'active_record'
require 'minitest/autorun'
require 'logger'
# This connection will do for database-independent bug reports.
ActiveRecord::Base.establish_connection(adapter: 'postgresql', database: 'test123')
ActiveRecord::Base.logger = Logger.new(STDOUT)
class Person
end
class Manager < Person
def say
puts "welcome"
end
end
class Manager
== Installing dependencies ==
Using rake 10.3.2
Using i18n 0.6.9
Using json 1.8.1
Using minitest 5.3.4
Using thread_safe 0.3.3
Using tzinfo 1.1.0
Using activesupport 4.1.0
Using builder 3.2.2
Using erubis 2.7.0
@senny
senny / patch.diff
Last active August 29, 2015 14:01
4-1-stable backportable patch of https://github.com/rails/rails/issues/15369
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md
index c39240d..a8d3723 100644
--- a/activerecord/CHANGELOG.md
+++ b/activerecord/CHANGELOG.md
@@ -1,3 +1,10 @@
+* Keep PostgreSQL `hstore` and `json` attributes as `Hash` in `@attributes`.
+ Fixes duplication in combination with `store_accessor`.
+
+ Fixes #15369.
+
class ProjectForm < AbstractForm
attribute :name, required: true
association :tasks, records: 3 do
attribute :name, required: true
end
end
diff --git a/actionmailer/test/url_test.rb b/actionmailer/test/url_test.rb
index 589944f..5912e9a 100644
--- a/actionmailer/test/url_test.rb
+++ b/actionmailer/test/url_test.rb
@@ -12,6 +12,7 @@ end
class UrlTestMailer < ActionMailer::Base
default_url_options[:host] = 'www.basecamphq.com'
+ default_url_options[:protocol] = 'https'