Skip to content
This repository

Apr 13, 2011

  1. Konstantin Haase

    prepare for Tilt 1.3 (while remaining compatible with 1.2)

    authored April 13, 2011

Mar 13, 2011

  1. Konstantin Haase

    more tests for sessions

    authored March 13, 2011

Feb 21, 2011

  1. Konstantin Haase

    add some test guards for rbx

    authored February 21, 2011

Dec 24, 2010

  1. Konstantin Haase

    fix tests to pass with latest Nokogiri

    authored December 24, 2010

Dec 23, 2010

  1. Konstantin Haase

    fix tests for rdoc 3.0

    authored December 23, 2010

Sep 27, 2010

  1. Konstantin Haase

    Sets default content type according to template engine used instead o…

    …f just text/html.
    
    It does so by including a Mixin into the the returned string offering a content_type method. Therefore all of the following examples produce the expected results:
    
        # text/html
        get('/') do
          haml :index
        end
    
        # text/css
        get('/') do
          sass :index
        end
    
        # text/css
        get('/') do
          haml :index
          sass :index
        end
    
        # text/html
        get('/') do
          haml '= sass :index'
        end
    
    It also allows setting the default content type for a template engine:
    
        set :builder, :content_type => :html
    
    Tests and README adjustments (all languages) included.
    authored September 19, 2010

May 18, 2009

  1. Simon Rozet

    Use Rack::Test instead of Sinatra::Test for tests

    authored March 28, 2009 rtomayko committed May 18, 2009
  2. Simon Rozet

    Deprecation warning for auto-require of template engines

    authored May 02, 2009 rtomayko committed May 18, 2009

Apr 25, 2009

  1. Ryan Tomayko

    set RACK_ENV in test/helper.rb to ensure sane environment

    authored April 25, 2009
  2. Blake Mizerany

    closes #9779 Auto-require haml/erb/builder/sass

    this is causing thread-saftey issues.
    authored April 24, 2009

Mar 31, 2009

  1. Simon Rozet

    Clean up options tests

    authored March 26, 2009 rtomayko committed March 31, 2009
  2. Simon Rozet

    Use contest instead of test/spec/mini

    See <http://github.com/citrusbyte/contest> for more info. The
    contest.rb file is included under the test/ directory.
    authored March 26, 2009 rtomayko committed March 31, 2009

Mar 26, 2009

  1. Simon Rozet

    Initial Sinatra-specific ShowException middleware

    authored January 23, 2009 rtomayko committed March 26, 2009

Mar 02, 2009

  1. Blake Mizerany

    Set :environment to :test when Sinatra::Test is included

    authored March 01, 2009 rtomayko committed March 02, 2009

Feb 22, 2009

  1. Simon Rozet

    Set sensible defaults on Default for test env

    authored February 22, 2009

Feb 17, 2009

  1. Simon Rozet

    Add full test coverage for all options

    Test for host option
    Test for port option
    Test for server option
    Test for app_file option
    Test for the root option
    Test for the views option
    Test for the public option
    Test for reload option
    Test for lock option
    Tests for dump_errors, sessions, logging, and static options
    DRY-up options test setup
    Clean up tests for clean_trace options
    Test for run option
    Run options tests with default options
    Enable raise_errors options in test environment
    
    See: http://github.com/sr/sinatra/commits/options/
    authored February 14, 2009 rtomayko committed February 17, 2009
  2. Simon Rozet

    Allow lowercase context name in test/spec/mini

    authored February 14, 2009 rtomayko committed February 17, 2009
  3. Simon Rozet

    Don't depend on sinatra/test/unit in internal test

    authored February 14, 2009 rtomayko committed February 17, 2009

Feb 03, 2009

  1. Ryan Tomayko

    Make the specs run under new miniunit stuff in Ruby 1.9

    * Rename Sinatra::Test#test_request to make_request. miniunit
      runs test_XXX methods included from modules.
    * Make describe/it work with miniunit -- all kinds of weirdness
      here
    authored January 30, 2009

Jan 31, 2009

  1. Brandon Dimcheff

    Added route block params in routing statements [#140]

    authored January 28, 2009 rtomayko committed January 31, 2009

Jan 20, 2009

  1. Ryan Tomayko

    Don't require rubygems in tests; do fall back if necessary

    authored January 20, 2009
  2. Simon Rozet

    Convert tests to custom test/spec/mini [#87]

    The "spec" task has been removed and Rake's built in
    test helper is used to run specs now so we should be able to
    test with multiple installed versions of Ruby.
    authored January 20, 2009 rtomayko committed January 20, 2009

Jan 15, 2009

  1. Ryan Tomayko

    Allow assertions in mock_app request context

    I changed the ".should." style to use "fail" when we
    converted to test/unit style but I'd rather use asserts
    here.
    authored January 15, 2009

Jan 14, 2009

  1. Ryan Tomayko

    use Test::Unit style assertions in Sinatra specs

    authored January 14, 2009
  2. Ryan Tomayko

    Test framework refactoring

    * Adds test/helper.rb and moves mock_app and other code specific
      to testing the framework out of Sinatra::Test.
    * Do not require test/unit. The sinatra/test/unit,
      sinatra/test/spec, and sinatra/test/rspec files can be used to
      choose the framework.
    * Add Sinatra::TestHarness, which should act similar to the
      Rack::Session proposal here: http://gist.github.com/41270
    * Update the README with information on using the different test
      frameworks.
    authored January 13, 2009

Dec 21, 2008

  1. Ryan Tomayko

    I knew I shoulda taken that left turn at Hoboken

    This is a fairly large reworking of Sinatra's innards. Although
    most of the internal implementation has been modified, it
    provides the same basic feature set and is meant to be compatible
    with Sinatra 0.3.2.
    
    * The Event and EventContext classes have been removed. Sinatra
      applications are now defined within the class context of a
      Sinatra::Base subclass; each request is processed within a new
      instance.
    
    * Sinatra::Base can be used as a base class for multiple
      Rack applications within a single process and can be used as
      Rack middleware.
    
    * The routing and result type processing implementation has been
      simplified and enhanced a bit. There's a new route conditions
      system for things like :agent/:host matching and a request
      level #pass method has been added to allow an event handler to
      exit immediately, passing control to the next matching route.
    
    * Regular expressions may now be used in route patterns. Captures
      are available as an array from "params[:captures]".
    
    * The #body helper method now takes a block. The block is not
      evaluated until an attempt is made to read the body.
    
    * Options are now dynamically generated class attributes on the
      Sinatra::Base subclass (instead of OpenStruct); options are
      inherited by subclasses and may be overridden up the
      inheritance hierarchy. The Base.set manages all option related
      stuff.
    
    * The application file (app_file) detection heuristics are bit
      more sane now. This fixes some bugs with reloading and
      public/views directory detection. All thin / passenger issues
      of these type should be better now.
    
    * Error mappings are now split into to distinct layers: exception
      mappings and custom error pages. Exception mappings are registered
      with 'error(Exception)' and are run only when the app raises an
      exception. Custom error pages are registered with error(status_code)
      and are run any time the response has the status code specified.
      It's also possible to register an error page for a range of status
      codes: 'error(500..599)'.
    
    * The spec and unit testing extensions have been modified to take
      advantage of the ability to have multiple Sinatra applications.
      The Sinatra::Test module must be included within the TestCase
      in order to take advantage of these methods (unless the
      'sinatra/compat' library has been required).
    
    * Rebuilt specs from scratch for better coverage and
      organization. Sinatra 3.2 unit tests have been retained
      under ./compat to ensure a baseline level of compatibility with
      previous versions; use the 'rake compat' task to run these.
    
    A large number of existing Sinatra idioms have been deprecated but
    continue to be supported through the 'sinatra/compat' library.
    
    * The "set_option" and "set_options" methods have been deprecated
      due to redundancy; use "set".
    
    * The "env" option (Sinatra::Base.env) has been renamed to "environment"
      and deprecated because it's too easy to confuse with the request-level
      Rack environment Hash (Sinatra::Base#env).
    
    * The request level "stop" method has been renamed "halt" and
      deprecated. This is for consistency with `throw :halt`.
    
    * The request level "entity_tag" method has been renamed "etag" and
      deprecated. Both versions were previously supported.
    
    * The request level "headers" method has been deprecated. Use
      response['Header-Name'] to access and modify response headers.
    
    * Sinatra.application is deprecated. Use Sinatra::Application instead.
    
    * Setting Sinatra.application = nil to reset an application is
      deprecated. You shouldn't have to reset objects anymore.
    
    * The Sinatra.default_options Hash is deprecated. Modifying this object now
      results in "set(key, value)" invocations on the Sinatra::Base
      subclass.
    
    * The "body.to_result" convention has been deprecated.
    
    * The ServerError exception has been deprecated. Any Exception is now
      considered a ServerError.
    authored December 13, 2008

Aug 31, 2008

  1. Ryan Tomayko

    Rack 0.4 (remove vendor submodule)

    Use Rack gem instead of freezing.
    authored August 31, 2008

Nov 28, 2007

  1. throw :halt

    authored November 28, 2007
  2. returning

    authored November 28, 2007
  3. more tests

    authored November 27, 2007
  4. starting

    authored November 27, 2007

Nov 26, 2007

  1. * fixed reloading and warnings.

    * still get warnings when running tests with rake.  need to fix this
    authored November 25, 2007
  2. * reset! for tests

    * logging
    authored November 25, 2007

Nov 22, 2007

  1. Handle multiple errors with one block

    authored November 21, 2007

Nov 21, 2007

  1. * Tests for error dsl method

    * Extracted Test helpers out
    authored November 21, 2007
Something went wrong with that request. Please try again.