Permalink
Browse files

Rails 3.1.3, without the asset pipeline.

  • Loading branch information...
1 parent dcfb3fd commit a8c3d28bb81fe441200be256a14a7146a848ca7d @cmeiklejohn cmeiklejohn committed with qrush Mar 24, 2012
Showing with 113 additions and 93 deletions.
  1. +2 −2 Gemfile
  2. +82 −67 Gemfile.lock
  3. +1 −1 app/controllers/subscriptions_controller.rb
  4. +2 −2 app/models/rubygem.rb
  5. +1 −1 app/models/user.rb
  6. +4 −0 app/models/version.rb
  7. +1 −0 app/views/subscriptions/update.js.erb
  8. +0 −1 config/environments/development.rb
  9. +1 −0 config/initializers/requires.rb
  10. +2 −2 features/step_definitions/api_steps.rb
  11. +1 −1 test/functional/api/v1/web_hooks_controller_test.rb
  12. +4 −4 test/functional/subscriptions_controller_test.rb
  13. +1 −1 test/unit/dependency_test.rb
  14. +1 −1 test/unit/linkset_test.rb
  15. +1 −1 test/unit/ownership_test.rb
  16. +1 −1 test/unit/subscription_test.rb
  17. +2 −2 test/unit/user_test.rb
  18. +6 −6 test/unit/web_hook_test.rb
  19. BIN vendor/cache/abstract-1.0.0.gem
  20. BIN vendor/cache/actionmailer-3.0.12.gem
  21. BIN vendor/cache/actionmailer-3.1.4.gem
  22. BIN vendor/cache/actionpack-3.0.12.gem
  23. BIN vendor/cache/actionpack-3.1.4.gem
  24. BIN vendor/cache/activemodel-3.0.12.gem
  25. BIN vendor/cache/activemodel-3.1.4.gem
  26. BIN vendor/cache/activerecord-3.0.12.gem
  27. BIN vendor/cache/activerecord-3.1.4.gem
  28. BIN vendor/cache/activeresource-3.0.12.gem
  29. BIN vendor/cache/activeresource-3.1.4.gem
  30. BIN vendor/cache/activesupport-3.0.12.gem
  31. BIN vendor/cache/activesupport-3.1.4.gem
  32. BIN vendor/cache/arel-2.0.10.gem
  33. BIN vendor/cache/arel-2.2.3.gem
  34. BIN vendor/cache/builder-2.1.2.gem
  35. BIN vendor/cache/builder-3.0.0.gem
  36. BIN vendor/cache/database_cleaner-0.7.1.gem
  37. BIN vendor/cache/database_cleaner-0.7.2.gem
  38. BIN vendor/cache/erubis-2.6.6.gem
  39. BIN vendor/cache/erubis-2.7.0.gem
  40. BIN vendor/cache/excon-0.13.0.gem
  41. BIN vendor/cache/excon-0.9.6.gem
  42. BIN vendor/cache/fog-0.7.2.gem
  43. BIN vendor/cache/fog-1.1.2.gem
  44. BIN vendor/cache/hike-1.2.1.gem
  45. BIN vendor/cache/i18n-0.5.0.gem
  46. BIN vendor/cache/i18n-0.6.0.gem
  47. BIN vendor/cache/launchy-2.0.5.gem
  48. BIN vendor/cache/launchy-2.1.0.gem
  49. BIN vendor/cache/mail-2.2.19.gem
  50. BIN vendor/cache/mail-2.3.3.gem
  51. BIN vendor/cache/mime-types-1.17.2.gem
  52. BIN vendor/cache/mime-types-1.18.gem
  53. BIN vendor/cache/multi_json-1.0.4.gem
  54. BIN vendor/cache/multi_json-1.1.0.gem
  55. BIN vendor/cache/newrelic-redis-1.1.0.gem
  56. BIN vendor/cache/newrelic-redis-1.2.0.gem
  57. BIN vendor/cache/rack-1.2.5.gem
  58. BIN vendor/cache/rack-1.3.6.gem
  59. BIN vendor/cache/rack-cache-1.2.gem
  60. BIN vendor/cache/rack-mount-0.6.14.gem
  61. BIN vendor/cache/rack-mount-0.8.3.gem
  62. BIN vendor/cache/rack-protection-1.2.0.gem
  63. BIN vendor/cache/rack-ssl-1.3.2.gem
  64. BIN vendor/cache/rack-test-0.5.7.gem
  65. BIN vendor/cache/rack-test-0.6.1.gem
  66. BIN vendor/cache/{rails-3.0.12.gem → rails-3.1.4.gem}
  67. BIN vendor/cache/railties-3.0.12.gem
  68. BIN vendor/cache/railties-3.1.4.gem
  69. BIN vendor/cache/shoulda-2.11.3.gem
  70. BIN vendor/cache/shoulda-3.0.1.gem
  71. BIN vendor/cache/shoulda-context-1.0.0.gem
  72. BIN vendor/cache/shoulda-matchers-1.0.0.gem
  73. BIN vendor/cache/sinatra-1.2.8.gem
  74. BIN vendor/cache/sinatra-1.3.2.gem
  75. BIN vendor/cache/sprockets-2.0.3.gem
  76. BIN vendor/cache/test-unit-2.4.8.gem
  77. BIN vendor/cache/webmock-1.8.1.gem
  78. BIN vendor/cache/webmock-1.8.4.gem
View
@@ -1,6 +1,6 @@
source 'https://rubygems.org'
-gem 'rails', '~> 3.0.10'
+gem 'rails', '~> 3.1.0'
gem 'airbrake'
gem 'clearance', '~> 0.13.2'
@@ -43,7 +43,7 @@ group :test do
gem 'capybara'
gem 'cucumber-rails', :require => false
gem 'database_cleaner'
- gem 'factory_girl_rails'
+ gem 'factory_girl_rails', "~> 1.7.0"
gem 'launchy'
gem 'nokogiri'
gem 'rack-test', :require => 'rack/test'
View
@@ -1,39 +1,40 @@
GEM
remote: https://rubygems.org/
specs:
- abstract (1.0.0)
- actionmailer (3.0.12)
- actionpack (= 3.0.12)
- mail (~> 2.2.19)
- actionpack (3.0.12)
- activemodel (= 3.0.12)
- activesupport (= 3.0.12)
- builder (~> 2.1.2)
- erubis (~> 2.6.6)
- i18n (~> 0.5.0)
- rack (~> 1.2.5)
- rack-mount (~> 0.6.14)
- rack-test (~> 0.5.7)
- tzinfo (~> 0.3.23)
- activemodel (3.0.12)
- activesupport (= 3.0.12)
- builder (~> 2.1.2)
- i18n (~> 0.5.0)
- activerecord (3.0.12)
- activemodel (= 3.0.12)
- activesupport (= 3.0.12)
- arel (~> 2.0.10)
- tzinfo (~> 0.3.23)
- activeresource (3.0.12)
- activemodel (= 3.0.12)
- activesupport (= 3.0.12)
- activesupport (3.0.12)
+ actionmailer (3.1.4)
+ actionpack (= 3.1.4)
+ mail (~> 2.3.0)
+ actionpack (3.1.4)
+ activemodel (= 3.1.4)
+ activesupport (= 3.1.4)
+ builder (~> 3.0.0)
+ erubis (~> 2.7.0)
+ i18n (~> 0.6)
+ rack (~> 1.3.6)
+ rack-cache (~> 1.1)
+ rack-mount (~> 0.8.2)
+ rack-test (~> 0.6.1)
+ sprockets (~> 2.0.3)
+ activemodel (3.1.4)
+ activesupport (= 3.1.4)
+ builder (~> 3.0.0)
+ i18n (~> 0.6)
+ activerecord (3.1.4)
+ activemodel (= 3.1.4)
+ activesupport (= 3.1.4)
+ arel (~> 2.2.3)
+ tzinfo (~> 0.3.29)
+ activeresource (3.1.4)
+ activemodel (= 3.1.4)
+ activesupport (= 3.1.4)
+ activesupport (3.1.4)
+ multi_json (~> 1.0)
addressable (2.2.7)
airbrake (3.0.9)
activesupport
builder
- arel (2.0.10)
- builder (2.1.2)
+ arel (2.2.3)
+ builder (3.0.0)
capistrano (2.11.2)
highline
net-scp (>= 1.0.0)
@@ -67,7 +68,7 @@ GEM
cucumber (>= 1.1.8)
nokogiri (>= 1.5.0)
daemons (1.1.8)
- database_cleaner (0.7.1)
+ database_cleaner (0.7.2)
delayed_job (3.0.1)
activesupport (~> 3.0)
delayed_job_active_record (0.3.2)
@@ -76,24 +77,22 @@ GEM
diesel (0.1.5)
railties
diff-lcs (1.1.3)
- erubis (2.6.6)
- abstract (>= 1.0.0)
- excon (0.9.6)
+ erubis (2.7.0)
+ excon (0.13.0)
factory_girl (2.6.4)
activesupport (>= 2.3.9)
factory_girl_rails (1.7.0)
factory_girl (~> 2.6.0)
railties (>= 3.0.0)
ffi (1.0.11)
- fog (1.1.2)
+ fog (0.7.2)
builder
- excon (~> 0.9.0)
- formatador (~> 0.2.0)
+ excon (>= 0.6.1)
+ formatador (>= 0.1.3)
+ json
mime-types
- multi_json (~> 1.0.3)
- net-scp (~> 1.0.4)
net-ssh (>= 2.1.3)
- nokogiri (~> 1.5.0)
+ nokogiri (>= 1.4.4)
ruby-hmac
formatador (0.2.1)
gchartrb (0.8)
@@ -111,29 +110,29 @@ GEM
guard (>= 0.8.3)
high_voltage (1.1.1)
highline (1.6.11)
- i18n (0.5.0)
+ hike (1.2.1)
+ i18n (0.6.0)
jquery-rails (1.0.19)
railties (~> 3.0)
thor (~> 0.14)
json (1.6.5)
- launchy (2.0.5)
+ launchy (2.1.0)
addressable (~> 2.2.6)
- mail (2.2.19)
- activesupport (>= 2.3.6)
+ mail (2.3.3)
i18n (>= 0.4.0)
mime-types (~> 1.16)
treetop (~> 1.4.8)
method_source (0.7.1)
- mime-types (1.17.2)
- multi_json (1.0.4)
+ mime-types (1.18)
+ multi_json (1.1.0)
net-scp (1.0.4)
net-ssh (>= 1.99.1)
net-sftp (2.0.5)
net-ssh (>= 2.0.9)
net-ssh (2.3.0)
net-ssh-gateway (1.1.0)
net-ssh (>= 1.99.1)
- newrelic-redis (1.1.0)
+ newrelic-redis (1.2.0)
newrelic_rpm (~> 3.0)
redis (< 3.0)
newrelic_rpm (3.3.2.1)
@@ -146,31 +145,38 @@ GEM
coderay (~> 1.0.5)
method_source (~> 0.7.1)
slop (>= 2.4.4, < 3)
- rack (1.2.5)
+ rack (1.3.6)
+ rack-cache (1.2)
+ rack (>= 0.4)
rack-maintenance (0.3.0)
rack (>= 1.0)
- rack-mount (0.6.14)
+ rack-mount (0.8.3)
rack (>= 1.0.0)
- rack-test (0.5.7)
+ rack-protection (1.2.0)
+ rack
+ rack-ssl (1.3.2)
+ rack
+ rack-test (0.6.1)
rack (>= 1.0)
- rails (3.0.12)
- actionmailer (= 3.0.12)
- actionpack (= 3.0.12)
- activerecord (= 3.0.12)
- activeresource (= 3.0.12)
- activesupport (= 3.0.12)
+ rails (3.1.4)
+ actionmailer (= 3.1.4)
+ actionpack (= 3.1.4)
+ activerecord (= 3.1.4)
+ activeresource (= 3.1.4)
+ activesupport (= 3.1.4)
bundler (~> 1.0)
- railties (= 3.0.12)
+ railties (= 3.1.4)
rails-erd (0.4.5)
activerecord (~> 3.0)
activesupport (~> 3.0)
ruby-graphviz (~> 0.9.18)
- railties (3.0.12)
- actionpack (= 3.0.12)
- activesupport (= 3.0.12)
+ railties (3.1.4)
+ actionpack (= 3.1.4)
+ activesupport (= 3.1.4)
+ rack-ssl (~> 1.3.2)
rake (>= 0.8.7)
rdoc (~> 3.4)
- thor (~> 0.14.4)
+ thor (~> 0.14.6)
rake (0.9.2.2)
rdoc (3.12)
json (~> 1.4)
@@ -187,12 +193,21 @@ GEM
ffi (~> 1.0)
multi_json (~> 1.0)
rubyzip
- shoulda (2.11.3)
+ shoulda (3.0.1)
+ shoulda-context (~> 1.0.0)
+ shoulda-matchers (~> 1.0.0)
+ shoulda-context (1.0.0)
+ shoulda-matchers (1.0.0)
silent-postgres (0.1.1)
- sinatra (1.2.8)
- rack (~> 1.1)
- tilt (>= 1.2.2, < 2.0)
+ sinatra (1.3.2)
+ rack (~> 1.3, >= 1.3.6)
+ rack-protection (~> 1.2)
+ tilt (~> 1.3, >= 1.3.3)
slop (2.4.4)
+ sprockets (2.0.3)
+ hike (~> 1.2)
+ rack (~> 1.0)
+ tilt (~> 1.1, != 1.3.0)
term-ansicolor (1.0.7)
thor (0.14.6)
tilt (1.3.3)
@@ -203,7 +218,7 @@ GEM
tzinfo (0.3.32)
validates_formatting_of (0.5.0)
rails (~> 3.0)
- webmock (1.8.1)
+ webmock (1.8.4)
addressable (>= 2.2.7)
crack (>= 0.1.7)
will_paginate (3.0.3)
@@ -226,7 +241,7 @@ DEPENDENCIES
delayed_job (~> 3.0.0.pre)
delayed_job_active_record
excon
- factory_girl_rails
+ factory_girl_rails (~> 1.7.0)
fog
gchartrb
gravtastic
@@ -248,7 +263,7 @@ DEPENDENCIES
rack
rack-maintenance
rack-test
- rails (~> 3.0.10)
+ rails (~> 3.1.0)
rails-erd
rdoc
redis
@@ -15,7 +15,7 @@ def destroy
def render_toggle_or_unacceptable(success)
if success
- render(:update) { |page| page['.toggler'].toggle }
+ render :update
else
render :text => '', :status => :forbidden
end
View
@@ -5,7 +5,7 @@ class Rubygem < ActiveRecord::Base
has_many :ownerships, :dependent => :destroy
has_many :subscribers, :through => :subscriptions, :source => :user
has_many :subscriptions, :dependent => :destroy
- has_many :versions, :dependent => :destroy
+ has_many :versions, :dependent => :destroy, :validate => false
has_many :web_hooks, :dependent => :destroy
has_one :linkset, :dependent => :destroy
@@ -235,7 +235,7 @@ def monthly_downloads
end
def first_built_date
- versions.by_built_at.limit(1).last.built_at
+ versions.by_earliest_built_at.limit(1).last.built_at
end
private
View
@@ -79,7 +79,7 @@ def regenerate_token
end
def generate_api_key
- self.api_key = ActiveSupport::SecureRandom.hex(16)
+ self.api_key = SecureRandom.hex(16)
end
def total_downloads_count
View
@@ -54,6 +54,10 @@ def self.by_built_at
order("versions.built_at desc")
end
+ def self.by_earliest_built_at
+ order("versions.built_at asc")
+ end
+
def self.by_created_at
order('versions.created_at desc')
end
@@ -0,0 +1 @@
+$(".toggler").toggle();
@@ -3,7 +3,6 @@
config.whiny_nils = true
config.consider_all_requests_local = true
- config.action_view.debug_rjs = true
config.action_controller.perform_caching = false
config.active_support.deprecation = :log
config.action_mailer.raise_delivery_errors = false
@@ -5,3 +5,4 @@
require 'simple_ssl_requirement'
require 'patterns'
require 'active_support/builder'
+require 'rack/rewindable_input'
@@ -8,12 +8,12 @@
When /^I push the gem "([^\"]*)" with my API key$/ do |name|
api_key_header
path = File.join(TEST_DIR, name)
- page.driver.post api_v1_rubygems_path, File.read(path)
+ page.driver.post api_v1_rubygems_path, File.read(path), {"CONTENT_TYPE" => "application/octet-stream"}
end
When /^I push an invalid .gem file$/ do
api_key_header
- page.driver.post api_v1_rubygems_path, 'ZZZZZZZZZZZZZZZZZZ'
+ page.driver.post api_v1_rubygems_path, 'ZZZZZZZZZZZZZZZZZZ', {"CONTENT_TYPE" => "application/octet-stream"}
end
When /^I yank the gem "([^\"]*)" version "([^\"]*)" with my API key$/ do |name, version_number|
@@ -140,7 +140,7 @@ def self.should_respond_to(format)
should_respond_to(:xml) do |body|
children = Nokogiri.parse(body).root.children
Hash.from_xml(children[1].to_xml).update(
- 'all gems' => [Hash.from_xml(children[5].to_xml)['web_hook']]
+ 'all gems' => Hash.from_xml(children[3].to_xml).delete('all_gems')
)
end
@@ -12,7 +12,7 @@ class SubscriptionsControllerTest < ActionController::TestCase
setup do
@rubygem = Factory(:rubygem)
Factory(:version, :rubygem => @rubygem)
- post :create, :rubygem_id => @rubygem.to_param
+ post :create, :rubygem_id => @rubygem.to_param, :format => 'js'
end
should assign_to(:rubygem) { @rubygem }
@@ -27,7 +27,7 @@ class SubscriptionsControllerTest < ActionController::TestCase
@rubygem = Factory(:rubygem)
Factory(:version, :rubygem => @rubygem)
Factory(:subscription, :rubygem => @rubygem, :user => @user)
- post :create, :rubygem_id => @rubygem.to_param
+ post :create, :rubygem_id => @rubygem.to_param, :format => 'js'
end
should assign_to(:rubygem) { @rubygem }
@@ -38,7 +38,7 @@ class SubscriptionsControllerTest < ActionController::TestCase
setup do
@rubygem = Factory(:rubygem)
Factory(:version, :rubygem => @rubygem)
- delete :destroy, :rubygem_id => @rubygem.to_param
+ delete :destroy, :rubygem_id => @rubygem.to_param, :format => 'js'
end
should assign_to(:rubygem) { @rubygem }
@@ -50,7 +50,7 @@ class SubscriptionsControllerTest < ActionController::TestCase
@rubygem = Factory(:rubygem)
Factory(:version, :rubygem => @rubygem)
Factory(:subscription, :rubygem => @rubygem, :user => @user)
- delete :destroy, :rubygem_id => @rubygem.to_param
+ delete :destroy, :rubygem_id => @rubygem.to_param, :format => 'js'
end
should assign_to(:rubygem) { @rubygem }
Oops, something went wrong.

0 comments on commit a8c3d28

Please sign in to comment.