Sha256: 68c47fe40c05be9ed688cb78a2188661bfe3fb5424dd9ae65aae8c6c8b7a31d0
Contents?: true
Size: 807 Bytes
Versions: 20
Compression:
Stored size: 807 Bytes
Contents
require_relative "../test_helper" module Paths class HTTPTest < Minitest::Test describe IOStreams::Paths::HTTP do let :url do "http://example.com/index.html?count=10" end let :ssl_url do "https://example.com/index.html?count=10" end describe ".open" do it "reads http" do result = IOStreams::Paths::HTTP.new(url).read assert_includes result, "<html>" end it "reads https" do result = IOStreams::Paths::HTTP.new(ssl_url).read assert_includes result, "<html>" end it "does not support streams" do assert_raises URI::InvalidURIError do io = StringIO.new IOStreams::Paths::HTTP.new(io) end end end end end end
Version data entries
20 entries across 20 versions & 1 rubygems