Sha256: 648d1780c0e9c5d512d596b8de4de20691e18b6b40715184a44dc4487e259982

Contents?: true

Size: 444 Bytes

Versions: 8

Compression:

Stored size: 444 Bytes

Contents

require 'sinatra'
require 'json'

class TestServer < Sinatra::Base
  @@url = 'http://localhost:9292'

  use Rack::Auth::Basic, "SirenClient Test API" do |username, password|
    username == 'admin' and password == '1234'
  end

  before do
    content_type 'application/vnd.siren+json'
  end
end

# Require all the endpoint files that build the api.
Dir[File.expand_path(File.dirname(__FILE__)) + "/endpoints/*.rb"].each {|file| require file }

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
siren_client-2.0.1 spec/support/test_server.rb
siren_client-2.0.0 spec/support/test_server.rb
siren_client-1.0.2 spec/support/test_server.rb
siren_client-1.0.1 spec/support/test_server.rb
siren_client-1.0.0 spec/support/test_server.rb
siren_client-0.3.0 spec/support/test_server.rb
siren_client-0.2.1 spec/support/test_server.rb
siren_client-0.2.0 spec/support/test_server.rb