actionpack 3.0.0.rc → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (71) hide show
  1. data/CHANGELOG +11 -16
  2. data/README.rdoc +3 -3
  3. data/lib/abstract_controller/base.rb +28 -14
  4. data/lib/abstract_controller/callbacks.rb +22 -23
  5. data/lib/abstract_controller/helpers.rb +24 -7
  6. data/lib/abstract_controller/layouts.rb +12 -10
  7. data/lib/abstract_controller/view_paths.rb +7 -7
  8. data/lib/abstract_controller.rb +1 -0
  9. data/lib/action_controller/base.rb +165 -2
  10. data/lib/action_controller/deprecated/base.rb +11 -1
  11. data/lib/action_controller/deprecated/url_writer.rb +14 -0
  12. data/lib/action_controller/metal/http_authentication.rb +3 -3
  13. data/lib/action_controller/metal/responder.rb +2 -8
  14. data/lib/action_controller/middleware.rb +1 -1
  15. data/lib/action_controller/test_case.rb +2 -1
  16. data/lib/action_controller/vendor/html-scanner/html/document.rb +2 -2
  17. data/lib/action_controller/vendor/html-scanner/html/node.rb +29 -29
  18. data/lib/action_controller/vendor/html-scanner/html/sanitizer.rb +25 -25
  19. data/lib/action_controller/vendor/html-scanner/html/selector.rb +1 -1
  20. data/lib/action_controller/vendor/html-scanner/html/tokenizer.rb +8 -8
  21. data/lib/action_controller.rb +2 -1
  22. data/lib/action_dispatch/http/cache.rb +2 -2
  23. data/lib/action_dispatch/http/mime_negotiation.rb +1 -1
  24. data/lib/action_dispatch/http/mime_type.rb +10 -10
  25. data/lib/action_dispatch/http/parameters.rb +2 -2
  26. data/lib/action_dispatch/http/request.rb +7 -0
  27. data/lib/action_dispatch/http/url.rb +12 -2
  28. data/lib/action_dispatch/middleware/best_standards_support.rb +22 -0
  29. data/lib/action_dispatch/middleware/cookies.rb +29 -10
  30. data/lib/action_dispatch/middleware/flash.rb +7 -2
  31. data/lib/action_dispatch/middleware/session/abstract_store.rb +2 -5
  32. data/lib/action_dispatch/middleware/session/mem_cache_store.rb +1 -0
  33. data/lib/action_dispatch/middleware/show_exceptions.rb +2 -9
  34. data/lib/action_dispatch/middleware/stack.rb +1 -1
  35. data/lib/action_dispatch/railtie.rb +2 -1
  36. data/lib/action_dispatch/routing/deprecated_mapper.rb +1 -0
  37. data/lib/action_dispatch/routing/mapper.rb +120 -137
  38. data/lib/action_dispatch/routing/polymorphic_routes.rb +10 -10
  39. data/lib/action_dispatch/routing/route_set.rb +8 -5
  40. data/lib/action_dispatch/routing/url_for.rb +1 -1
  41. data/lib/action_dispatch/routing.rb +4 -4
  42. data/lib/action_dispatch/testing/assertions/dom.rb +1 -1
  43. data/lib/action_dispatch/testing/assertions/response.rb +5 -5
  44. data/lib/action_dispatch/testing/assertions/routing.rb +39 -16
  45. data/lib/action_dispatch/testing/integration.rb +1 -0
  46. data/lib/action_dispatch.rb +1 -0
  47. data/lib/action_pack/version.rb +1 -2
  48. data/lib/action_view/base.rb +1 -0
  49. data/lib/action_view/helpers/asset_tag_helper.rb +12 -0
  50. data/lib/action_view/helpers/capture_helper.rb +1 -1
  51. data/lib/action_view/helpers/date_helper.rb +13 -17
  52. data/lib/action_view/helpers/debug_helper.rb +1 -1
  53. data/lib/action_view/helpers/form_helper.rb +16 -10
  54. data/lib/action_view/helpers/form_options_helper.rb +21 -18
  55. data/lib/action_view/helpers/form_tag_helper.rb +9 -9
  56. data/lib/action_view/helpers/number_helper.rb +1 -1
  57. data/lib/action_view/helpers/raw_output_helper.rb +1 -1
  58. data/lib/action_view/helpers/sanitize_helper.rb +4 -2
  59. data/lib/action_view/helpers/text_helper.rb +5 -2
  60. data/lib/action_view/helpers/translation_helper.rb +9 -9
  61. data/lib/action_view/helpers/url_helper.rb +2 -2
  62. data/lib/action_view/log_subscriber.rb +1 -1
  63. data/lib/action_view/render/layouts.rb +8 -4
  64. data/lib/action_view/render/partials.rb +1 -1
  65. data/lib/action_view/template/handler.rb +1 -1
  66. data/lib/action_view/template/handlers.rb +1 -1
  67. data/lib/action_view/template/resolver.rb +15 -0
  68. data/lib/action_view/template.rb +3 -3
  69. data/lib/action_view/test_case.rb +1 -1
  70. data/lib/action_view/testing/resolvers.rb +1 -1
  71. metadata +20 -23
@@ -1,5 +1,6 @@
1
1
  require 'active_support/core_ext/array/wrap'
2
2
  require 'active_support/core_ext/object/blank'
3
+ require 'active_support/core_ext/object/try'
3
4
  require 'active_support/core_ext/kernel/singleton_class'
4
5
 
5
6
  module ActionView
@@ -113,12 +114,11 @@ module ActionView
113
114
  @identifier = identifier
114
115
  @handler = handler
115
116
  @original_encoding = nil
116
-
117
- @virtual_path = details[:virtual_path]
118
- @method_names = {}
117
+ @method_names = {}
119
118
 
120
119
  format = details[:format] || :html
121
120
  @formats = Array.wrap(format).map(&:to_sym)
121
+ @virtual_path = details[:virtual_path].try(:sub, ".#{format}", "")
122
122
  end
123
123
 
124
124
  def render(view, locals, &block)
@@ -44,7 +44,7 @@ module ActionView
44
44
  include ActionView::Helpers
45
45
 
46
46
  attr_accessor :controller, :output_buffer, :rendered
47
-
47
+
48
48
  module ClassMethods
49
49
  def tests(helper_class)
50
50
  self.helper_class = helper_class
@@ -38,6 +38,6 @@ module ActionView #:nodoc:
38
38
  [ActionView::Template.new("Template generated by Null Resolver", path, handler, :virtual_path => path, :format => format)]
39
39
  end
40
40
  end
41
-
41
+
42
42
  end
43
43
 
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionpack
3
3
  version: !ruby/object:Gem::Version
4
- hash: 7712042
5
- prerelease: true
4
+ hash: 7
5
+ prerelease: false
6
6
  segments:
7
7
  - 3
8
8
  - 0
9
9
  - 0
10
- - rc
11
- version: 3.0.0.rc
10
+ version: 3.0.0
12
11
  platform: ruby
13
12
  authors:
14
13
  - David Heinemeier Hansson
@@ -16,7 +15,7 @@ autorequire:
16
15
  bindir: bin
17
16
  cert_chain: []
18
17
 
19
- date: 2010-07-26 00:00:00 -05:00
18
+ date: 2010-08-29 00:00:00 -05:00
20
19
  default_executable:
21
20
  dependencies:
22
21
  - !ruby/object:Gem::Dependency
@@ -27,13 +26,12 @@ dependencies:
27
26
  requirements:
28
27
  - - "="
29
28
  - !ruby/object:Gem::Version
30
- hash: 7712042
29
+ hash: 7
31
30
  segments:
32
31
  - 3
33
32
  - 0
34
33
  - 0
35
- - rc
36
- version: 3.0.0.rc
34
+ version: 3.0.0
37
35
  type: :runtime
38
36
  version_requirements: *id001
39
37
  - !ruby/object:Gem::Dependency
@@ -44,13 +42,12 @@ dependencies:
44
42
  requirements:
45
43
  - - "="
46
44
  - !ruby/object:Gem::Version
47
- hash: 7712042
45
+ hash: 7
48
46
  segments:
49
47
  - 3
50
48
  - 0
51
49
  - 0
52
- - rc
53
- version: 3.0.0.rc
50
+ version: 3.0.0
54
51
  type: :runtime
55
52
  version_requirements: *id002
56
53
  - !ruby/object:Gem::Dependency
@@ -125,12 +122,12 @@ dependencies:
125
122
  requirements:
126
123
  - - ~>
127
124
  - !ruby/object:Gem::Version
128
- hash: 21
125
+ hash: 31
129
126
  segments:
130
127
  - 0
131
128
  - 6
132
- - 9
133
- version: 0.6.9
129
+ - 12
130
+ version: 0.6.12
134
131
  type: :runtime
135
132
  version_requirements: *id007
136
133
  - !ruby/object:Gem::Dependency
@@ -141,12 +138,12 @@ dependencies:
141
138
  requirements:
142
139
  - - ~>
143
140
  - !ruby/object:Gem::Version
144
- hash: 63
141
+ hash: 61
145
142
  segments:
146
143
  - 0
147
144
  - 3
148
- - 22
149
- version: 0.3.22
145
+ - 23
146
+ version: 0.3.23
150
147
  type: :runtime
151
148
  version_requirements: *id008
152
149
  - !ruby/object:Gem::Dependency
@@ -198,6 +195,7 @@ files:
198
195
  - lib/action_controller/deprecated/dispatcher.rb
199
196
  - lib/action_controller/deprecated/integration_test.rb
200
197
  - lib/action_controller/deprecated/performance_test.rb
198
+ - lib/action_controller/deprecated/url_writer.rb
201
199
  - lib/action_controller/deprecated.rb
202
200
  - lib/action_controller/log_subscriber.rb
203
201
  - lib/action_controller/metal/compatibility.rb
@@ -248,6 +246,7 @@ files:
248
246
  - lib/action_dispatch/http/response.rb
249
247
  - lib/action_dispatch/http/upload.rb
250
248
  - lib/action_dispatch/http/url.rb
249
+ - lib/action_dispatch/middleware/best_standards_support.rb
251
250
  - lib/action_dispatch/middleware/callbacks.rb
252
251
  - lib/action_dispatch/middleware/cookies.rb
253
252
  - lib/action_dispatch/middleware/flash.rb
@@ -359,14 +358,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
359
358
  required_rubygems_version: !ruby/object:Gem::Requirement
360
359
  none: false
361
360
  requirements:
362
- - - ">"
361
+ - - ">="
363
362
  - !ruby/object:Gem::Version
364
- hash: 25
363
+ hash: 3
365
364
  segments:
366
- - 1
367
- - 3
368
- - 1
369
- version: 1.3.1
365
+ - 0
366
+ version: "0"
370
367
  requirements:
371
368
  - none
372
369
  rubyforge_project: actionpack