Skip to content

Commit c655c17

Browse files
coneybearemshibuya
authored andcommitted
Add the test cases from #2473
1 parent c3b4cc6 commit c655c17

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

spec/downloader/base_spec.rb

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,22 @@
4141
end
4242
end
4343

44+
context "with equal and colons in the query path" do
45+
let(:query) { 'test=query&with=equal&before=colon:param' }
46+
let(:uri) { "https://example.com/#{filename}?#{query}" }
47+
before do
48+
stub_request(:get, uri).to_return(body: file)
49+
end
50+
51+
it "leaves colon in resulting URI" do
52+
expect(subject.process_uri(uri).query).to eq query
53+
end
54+
55+
it "downloads a file" do
56+
expect(subject.download(uri).file.read).to eq file
57+
end
58+
end
59+
4460
context 'with request headers' do
4561
let(:authentication_headers) do
4662
{

0 commit comments

Comments
 (0)