From b9ac3fef8fcd0b6b2eb87d8ce4410dd474848e56 Mon Sep 17 00:00:00 2001 From: Dylan Thacker-Smith Date: Sat, 18 Oct 2014 16:25:50 -0400 Subject: [PATCH] Remove the quotes from the partial string in the profiler timing objects. --- lib/liquid/profiler/hooks.rb | 2 +- test/integration/render_profiling_test.rb | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/liquid/profiler/hooks.rb b/lib/liquid/profiler/hooks.rb index e752c5e..dfad85d 100644 --- a/lib/liquid/profiler/hooks.rb +++ b/lib/liquid/profiler/hooks.rb @@ -12,7 +12,7 @@ module Liquid class Include < Tag def render_with_profiling(context) - Profiler.profile_children("'#{context.evaluate(@template_name)}'") do + Profiler.profile_children(context.evaluate(@template_name).to_s) do render_without_profiling(context) end end diff --git a/test/integration/render_profiling_test.rb b/test/integration/render_profiling_test.rb index 48f433d..d97f2ae 100644 --- a/test/integration/render_profiling_test.rb +++ b/test/integration/render_profiling_test.rb @@ -89,7 +89,7 @@ class RenderProfilingTest < Minitest::Test include_node = t.profiler[1] include_node.children.each do |child| - assert_equal "'a_template'", child.partial + assert_equal "a_template", child.partial end end @@ -99,12 +99,12 @@ class RenderProfilingTest < Minitest::Test a_template = t.profiler[1] a_template.children.each do |child| - assert_equal "'a_template'", child.partial + assert_equal "a_template", child.partial end b_template = t.profiler[2] b_template.children.each do |child| - assert_equal "'b_template'", child.partial + assert_equal "b_template", child.partial end end @@ -114,12 +114,12 @@ class RenderProfilingTest < Minitest::Test a_template1 = t.profiler[1] a_template1.children.each do |child| - assert_equal "'a_template'", child.partial + assert_equal "a_template", child.partial end a_template2 = t.profiler[2] a_template2.children.each do |child| - assert_equal "'a_template'", child.partial + assert_equal "a_template", child.partial end end