fiveruns-dash-rails 0.8.5 → 0.8.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -18,4 +18,4 @@ if START_FIVERUNS_DASH_RAILS
18
18
  end
19
19
  require 'fiveruns/dash/rails/context/template'
20
20
  require File.dirname(__FILE__) << "/../rails/init"
21
- end
21
+ end
@@ -189,4 +189,4 @@ if START_FIVERUNS_DASH_RAILS
189
189
 
190
190
  end
191
191
 
192
- end
192
+ end
@@ -26,6 +26,7 @@ module Fiveruns::Dash::Rails::Context
26
26
  else
27
27
  path
28
28
  end
29
+
29
30
  # Remove extensions, if any
30
31
  path.sub(/\.[^\/\\]*$/, '')
31
32
  end
@@ -37,7 +38,7 @@ module Fiveruns::Dash::Rails::Context
37
38
 
38
39
  begin
39
40
  Fiveruns::Dash::Context.context << 'view'
40
- if respond_to?(:path)
41
+ if respond_to?(:path) && !self.is_a?(ActionView::InlineTemplate)
41
42
  Fiveruns::Dash::Context.context << Fiveruns::Dash::Rails::Context::Template.sanitize_view_path(path)
42
43
  else
43
44
  Fiveruns::Dash::Context.context << '(inline)'
@@ -55,3 +56,4 @@ module Fiveruns::Dash::Rails::Context
55
56
  end
56
57
 
57
58
  end
59
+
@@ -16,4 +16,4 @@ Fiveruns::Dash.register_recipe :actionpack, :url => 'http://dash.fiveruns.com' d
16
16
  Fiveruns::Dash.logger.warn 'Collection of "render_time" unsupported for this version of Rails'
17
17
  end
18
18
 
19
- end
19
+ end
@@ -1,4 +1,3 @@
1
- # Rails #######################################################################
2
1
  Fiveruns::Dash.register_recipe :rails, :url => 'http://dash.fiveruns.com' do |recipe|
3
2
 
4
3
  if defined?(ActiveRecord)
@@ -62,16 +61,33 @@ Fiveruns::Dash.register_recipe :rails, :url => 'http://dash.fiveruns.com' do |re
62
61
  recipe.added do
63
62
 
64
63
  if defined?(ActiveRecord)
65
- ActiveRecord::Base.send(:include, Fiveruns::Dash::Rails::Context::ActiveRecord)
64
+ ActiveRecord::Base.send(:include,
65
+ Fiveruns::Dash::Rails::Context::ActiveRecord)
66
66
  end
67
- ActionController::Base.send(:include, Fiveruns::Dash::Rails::Context::Action)
67
+
68
+ ActionController::Base.send(:include,
69
+ Fiveruns::Dash::Rails::Context::Action)
68
70
 
69
71
  if defined?(ActionView::Renderable)
70
- ActionView::Renderable.send(:include, Fiveruns::Dash::Rails::Context::Template)
72
+ ActionView::Renderable.send(:include,
73
+ Fiveruns::Dash::Rails::Context::Template)
71
74
  else
72
- ActionView::Template.send(:include, Fiveruns::Dash::Rails::Context::Template) if defined?(ActionView::Template)
73
- ActionView::InlineTemplate.send(:include, Fiveruns::Dash::Rails::Context::Template) if defined?(ActionView::InlineTemplate)
74
- ActionView::PartialTemplate.send(:include, Fiveruns::Dash::Rails::Context::Template) if defined?(ActionView::PartialTemplate)
75
+ if defined?(ActionView::Template)
76
+ ActionView::Template.send(:include,
77
+ Fiveruns::Dash::Rails::Context::Template)
78
+ end
79
+
80
+ if defined?(ActionView::InlineTemplate) &&
81
+ Gem::Requirement.new('>= 2.2.0').
82
+ satisfied_by?(Gem::Version.new(Rails.version))
83
+ ActionView::InlineTemplate.send(:include,
84
+ Fiveruns::Dash::Rails::Context::Template)
85
+ end
86
+
87
+ if defined?(ActionView::PartialTemplate)
88
+ ActionView::PartialTemplate.send(:include,
89
+ Fiveruns::Dash::Rails::Context::Template)
90
+ end
75
91
  end
76
92
 
77
93
  begin
data/version.yml CHANGED
@@ -1,4 +1,4 @@
1
1
  ---
2
2
  :major: 0
3
3
  :minor: 8
4
- :patch: 5
4
+ :patch: 6
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fiveruns-dash-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.5
4
+ version: 0.8.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - FiveRuns Development Team
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-03-18 00:00:00 -07:00
12
+ date: 2009-04-08 00:00:00 -07:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency