Skip to content

Commit

Permalink
Merge branch '83-ruby-2.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
marnen committed Oct 31, 2014
2 parents 7be627a + d4f8182 commit 9facdbe
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 13 deletions.
1 change: 0 additions & 1 deletion .rspec
Expand Up @@ -3,4 +3,3 @@
progress
--format
html --out spec-results/index.html
--debugger
1 change: 0 additions & 1 deletion .ruby-gemset

This file was deleted.

1 change: 0 additions & 1 deletion .ruby-version

This file was deleted.

5 changes: 4 additions & 1 deletion Gemfile
@@ -1,5 +1,7 @@
source 'http://rubygems.org'

ruby '2.0.0'

gem 'rails', github: 'rails/rails', branch: '3-0-stable'
# TODO: go back to released gem if 5aeb472d990fef093a3d674bd20e4e9eb45ac962 gets incorporated into 3.0.21 (or when we upgrade to 3.2).

Expand All @@ -26,6 +28,7 @@ gem 'haml'
gem 'sass'
gem 'pg'
gem 'gettext_i18n_rails'
gem 'iconv'
gem 'prawn'
gem 'geocoder', '~> 1.1.8'
gem 'rdiscount'
Expand All @@ -51,7 +54,7 @@ group :test, :development do
gem 'autotest-rails', :require => false
gem 'rspec-rails', '~> 2.11.0', :require => false
gem 'test-unit', '1.2.3', :require => false # amazingly, RSpec needs this
gem 'debugger'
gem 'byebug'
gem 'cucumber-rails', :require => false
gem 'launchy'
gem 'pickle'
Expand Down
16 changes: 9 additions & 7 deletions Gemfile.lock
Expand Up @@ -69,6 +69,10 @@ GEM
autotest-rails (4.1.0)
ZenTest
builder (2.1.2)
byebug (3.5.1)
columnize (~> 0.8)
debugger-linecache (~> 1.2)
slop (~> 3.6)
capistrano (2.15.5)
highline
net-scp (>= 1.0.0)
Expand All @@ -84,7 +88,7 @@ GEM
xpath (~> 0.1.4)
childprocess (0.2.2)
ffi (~> 1.0.6)
columnize (0.3.6)
columnize (0.8.9)
cucumber (1.0.2)
builder (>= 2.1.2)
diff-lcs (>= 1.1.2)
Expand All @@ -96,12 +100,7 @@ GEM
cucumber (~> 1.0.0)
nokogiri (>= 1.4.6)
database_cleaner (1.1.1)
debugger (1.6.3)
columnize (>= 0.3.1)
debugger-linecache (~> 1.2.0)
debugger-ruby_core_source (~> 1.2.4)
debugger-linecache (1.2.0)
debugger-ruby_core_source (1.2.4)
diff-lcs (1.1.3)
dynamic_form (1.1.4)
erubis (2.6.6)
Expand All @@ -127,6 +126,7 @@ GEM
hoe (3.5.0)
rake (>= 0.8, < 11.0)
i18n (0.5.2)
iconv (1.0.4)
json (1.8.0)
json_pure (1.5.4)
spruz (~> 0.2.8)
Expand Down Expand Up @@ -186,6 +186,7 @@ GEM
ffi (>= 1.0.7)
json_pure
rubyzip
slop (3.6.0)
spruz (0.2.13)
term-ansicolor (1.0.6)
test-unit (1.2.3)
Expand All @@ -205,9 +206,9 @@ DEPENDENCIES
activerecord-postgis-adapter
authlogic (~> 3.0.3)
autotest-rails
byebug
cucumber-rails
database_cleaner
debugger
dynamic_form
exception_notification
factory_girl_rails
Expand All @@ -216,6 +217,7 @@ DEPENDENCIES
gettext (>= 1.9.3)
gettext_i18n_rails
haml
iconv
launchy
pg
pickle
Expand Down
4 changes: 3 additions & 1 deletion config/application.rb
Expand Up @@ -10,6 +10,8 @@

module Quorum2
class Application < Rails::Application
ActionController::Base.config.relative_url_root = '' # TODO: remove when we upgrade to Rails 3.2; see https://github.com/rails/rails/issues/9619

# Settings in config/environments/* take precedence over those specified here.
# Application configuration should go into files in config/initializers
# -- all .rb files in that directory are automatically loaded.
Expand Down Expand Up @@ -40,7 +42,7 @@ class Application < Rails::Application

# Configure sensitive parameters which will be filtered from the log file.
config.filter_parameters += [:password]

config.generators do |g|
g.template_engine :haml
g.test_framework :rspec, :fixture => false
Expand Down
18 changes: 18 additions & 0 deletions config/initializers/has_many_patch.rb
@@ -0,0 +1,18 @@
# TODO: remove when we upgrade to Rails 3.2; see https://github.com/rails/rails/issues/11026

if Rails::VERSION::MAJOR == 3 && Rails::VERSION::MINOR == 0 && RUBY_VERSION >= "2.0.0"
module ActiveRecord
module Associations
class AssociationProxy
def send(method, *args)
if proxy_respond_to?(method, true)
super
else
load_target
@target.send(method, *args)
end
end
end
end
end
end
2 changes: 1 addition & 1 deletion spec/views/events/new.html.haml_spec.rb
Expand Up @@ -28,7 +28,7 @@
end

it "should have a Markdown hint in the description field" do
header = assert_select("table.edit th", /Description/)
header = assert_select("table.edit th", /Description/).first
header.should_not be_nil
header.should have_selector("a", :content => 'Markdown')
end
Expand Down

0 comments on commit 9facdbe

Please sign in to comment.