Skip to content
This repository

Jun 15, 2011

  1. Konstantin Haase

    rename public to public_folder, fixes #301

    rkh authored

Jun 06, 2011

  1. adds check for :static_cache_control setting to Sinatra::Base.static!

    kenichi nakamura authored

May 11, 2011

  1. Konstantin Haase

    adjust require lines for test helper, so it also works properly on 1.9.2

    rkh authored

Oct 19, 2010

  1. Мар'ян Крекотень (Marjan Krekoteń)

    Rename test_valid_range to assert_valid_range

    MiniTets treats all /test.*/ methods as test examples.
    
    Signed-off-by: Konstantin Haase <konstantin.mailinglists@googlemail.com>
    krekoten authored rkh committed

Oct 17, 2010

  1. Jens Alfke

    Re-implement byte-range support for static files.

    Correct handling of "Range:" request header. Replaces buggy implementation (480b1e8, 44ab090) that was recently backed out.
    Fixes #93.
    
    NOTE: Does not yet support multiple ranges (e.g. "bytes=1-10,20-30") because that requires sending a multipart response, which is more complex than I want to get into now.
    
    Signed-off-by: Konstantin Haase <konstantin.mailinglists@googlemail.com>
    snej authored rkh committed
  2. Konstantin Haase

    Remove buggy support for range requests for now. Reverts 480b1e8 and 4…

    rkh authored

Oct 10, 2010

  1. JP Hastings-Spital

    send_file now copes with 'Range: bytes=100-400,500-600' headers

    Signed-off-by: Konstantin Haase <konstantin.mailinglists@googlemail.com>
    jphastings authored rkh committed

Jan 28, 2010

  1. Ryan Tomayko

    set sinara.static_file env var when serving static files

    rtomayko authored

Jun 07, 2009

  1. Ryan Tomayko

    Better route and filter inheritance [#180]

    rtomayko authored

Mar 31, 2009

  1. 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.
    sr authored rtomayko committed

Mar 09, 2009

  1. Ryan Tomayko

    Fix directory traversal vulnerability in static file route [#177]

    rtomayko authored

Feb 03, 2009

  1. Ryan Tomayko

    Fix constant resolution in specs under 1.9

    The way constants are set/resolved in class_eval blocks seems
    to have changed significantly. Move constants to top-level to
    remedy the situation for now.
    rtomayko authored

Jan 21, 2009

  1. Ryan Tomayko

    Make static files work with Rack::Lint in the pipeline [#121]

    rtomayko authored

Jan 14, 2009

  1. Ryan Tomayko

    use Test::Unit style assertions in Sinatra specs

    rtomayko authored
  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.
    rtomayko authored

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.
    rtomayko authored

Feb 25, 2008

  1. Streaming

    Blake Mizerany authored

Dec 02, 2007

  1. tests

    Blake Mizerany authored

Nov 28, 2007

  1. starting

    Blake Mizerany authored

Nov 26, 2007

  1. * reset! for tests

    * logging
    Blake Mizerany authored

Nov 24, 2007

  1. static files

    Blake Mizerany authored
Something went wrong with that request. Please try again.