Sha256: 6bad00361ade6a1cd538ace4032782d71a9084c7c8f8f4e9c3f7d90ae1151164

Contents?: true

Size: 435 Bytes

Versions: 8

Compression:

Stored size: 435 Bytes

Contents

require File.expand_path("spec_helper", File.dirname(File.dirname(__FILE__)))

describe "symbol_status plugin" do
  it "accepts a symbol" do
    app(:symbol_status) do |r|
      r.on do
        response.status = :unauthorized
      end
    end

    status.must_equal 401
  end

  it "accepts a fixnum" do
    app(:symbol_status) do |r|
      r.on do
        response.status = 204
      end
    end

    status.must_equal 204
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
roda-2.21.0 spec/plugin/symbol_status_spec.rb
roda-2.20.0 spec/plugin/symbol_status_spec.rb
roda-2.19.0 spec/plugin/symbol_status_spec.rb
roda-2.18.0 spec/plugin/symbol_status_spec.rb
roda-2.17.0 spec/plugin/symbol_status_spec.rb
roda-2.16.0 spec/plugin/symbol_status_spec.rb
roda-2.15.0 spec/plugin/symbol_status_spec.rb
roda-2.14.0 spec/plugin/symbol_status_spec.rb