From ceac46f0bc129a6e994a06100aa854f606fe5992 Mon Sep 17 00:00:00 2001 From: Simon Rozet Date: Mon, 1 Mar 2010 16:07:57 -0800 Subject: [PATCH] fix whitespace errors --- lib/sinatra/base.rb | 2 +- test/less_test.rb | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/sinatra/base.rb b/lib/sinatra/base.rb index f027a960..406008f9 100644 --- a/lib/sinatra/base.rb +++ b/lib/sinatra/base.rb @@ -304,7 +304,7 @@ module Sinatra options[:layout] = false render :sass, template, options, locals end - + def less(template, options={}, locals={}) options[:layout] = false render :less, template, options, locals diff --git a/test/less_test.rb b/test/less_test.rb index 9ce9aa9b..f6cd72fd 100644 --- a/test/less_test.rb +++ b/test/less_test.rb @@ -9,25 +9,25 @@ class LessTest < Test::Unit::TestCase } get '/' end - + it 'renders inline Less strings' do less_app { less "@white_color: #fff; #main { background-color: @white_color }"} assert ok? assert_equal "#main { background-color: #ffffff; }\n", body end - + it 'renders .less files in views path' do less_app { less :hello } assert ok? assert_equal "#main { background-color: #ffffff; }\n", body end - + it 'ignores the layout option' do less_app { less :hello, :layout => :layout2 } assert ok? assert_equal "#main { background-color: #ffffff; }\n", body end - + it "raises error if template not found" do mock_app { get('/') { less :no_such_template }