mirror of
https://github.com/discourse/discourse.git
synced 2025-05-29 01:31:35 +08:00
FIX: don't double request when downloading a file
This commit is contained in:
@ -4,8 +4,8 @@ require_dependency 'oneboxer'
|
||||
describe Oneboxer do
|
||||
|
||||
it "returns blank string for an invalid onebox" do
|
||||
stub_request(:head, "http://boom.com")
|
||||
stub_request(:get, "http://boom.com").to_return(body: "")
|
||||
stub_request(:head, "http://boom.com").to_return(body: "")
|
||||
|
||||
expect(Oneboxer.preview("http://boom.com")).to eq("")
|
||||
expect(Oneboxer.onebox("http://boom.com")).to eq("")
|
||||
|
Reference in New Issue
Block a user