mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
adjust require lines for test helper, so it also works properly on 1.9.2
This commit is contained in:
parent
5a899b2df3
commit
e001d62669
34 changed files with 34 additions and 34 deletions
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class BaseTest < Test::Unit::TestCase
|
||||
def test_default
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'builder'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'coffee-script'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'creole'
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# encoding: UTF-8
|
||||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
require 'erb'
|
||||
|
||||
class BaseTest < Test::Unit::TestCase
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class ERBTest < Test::Unit::TestCase
|
||||
def engine
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class ExtensionsTest < Test::Unit::TestCase
|
||||
module FooExtensions
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class BeforeFilterTest < Test::Unit::TestCase
|
||||
it "executes filters in the order defined" do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'haml'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
require 'date'
|
||||
|
||||
class HelpersTest < Test::Unit::TestCase
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'less'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'liquid'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class FooError < RuntimeError
|
||||
end
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'markaby'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
MarkdownTest = proc do
|
||||
def markdown_app(&block)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class MiddlewareTest < Test::Unit::TestCase
|
||||
setup do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'nokogiri'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'radius'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'rdoc/markup/to_html'
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# Tests to check if all the README examples work.
|
||||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class ReadmeTest < Test::Unit::TestCase
|
||||
example do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
require 'stringio'
|
||||
|
||||
class RequestTest < Test::Unit::TestCase
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# encoding: utf-8
|
||||
|
||||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class ResponseTest < Test::Unit::TestCase
|
||||
setup do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class ResultTest < Test::Unit::TestCase
|
||||
it "sets response.body when result is a String" do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
module RouteAddedTest
|
||||
@routes, @procs = [], []
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# I like coding: UTF-8
|
||||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
# Helper method for easy route pattern matching testing
|
||||
def route_def(pattern)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'sass'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'sass'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
module Rack::Handler
|
||||
class Mock
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class SettingsTest < Test::Unit::TestCase
|
||||
setup do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class SinatraTest < Test::Unit::TestCase
|
||||
it 'creates a new Sinatra::Base subclass on new' do
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'slim'
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
class StaticTest < Test::Unit::TestCase
|
||||
setup do
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# encoding: UTF-8
|
||||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
File.delete(File.dirname(__FILE__) + '/views/layout.test') rescue nil
|
||||
|
||||
class TestTemplate < Tilt::Template
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
require File.expand_path('../helper', __FILE__)
|
||||
|
||||
begin
|
||||
require 'redcloth'
|
||||
|
|
Loading…
Reference in a new issue