Sha256: 747a6e54e12f48de50f9a796a405d0a27b126566eafff22613882ab678a9ee7c
Contents?: true
Size: 511 Bytes
Versions: 17
Compression:
Stored size: 511 Bytes
Contents
require 'minitest_helper' describe Rasti::Web::Endpoint do it 'Call' do endpoint = Rasti::Web::Endpoint.new do |req, res, render| req.must_be_instance_of Rasti::Web::Request res.must_be_instance_of Rack::Response render.text 'Content' end env = Rack::MockRequest.env_for '/' status, headers, response = endpoint.call env status.must_equal 200 headers['Content-Type'].must_equal 'text/plain; charset=utf-8' response.body.must_equal ['Content'] end end
Version data entries
17 entries across 17 versions & 1 rubygems