diff --git a/spec/http_spec.cr b/spec/http_spec.cr index 167206c..3cdfca3 100644 --- a/spec/http_spec.cr +++ b/spec/http_spec.cr @@ -1,5 +1,4 @@ require "./spec_helper" -require "webmock" WebMock.stub(:get, "example.com") WebMock.stub(:get, "http://example.com/?foo=bar&foo1=bar2") diff --git a/spec/page_spec.cr b/spec/page_spec.cr index a40e0a2..b69ff22 100644 --- a/spec/page_spec.cr +++ b/spec/page_spec.cr @@ -1,5 +1,4 @@ require "./spec_helper" -require "webmock" WebMock.stub(:get, "example.com") WebMock.stub(:get, "fail_example.com").to_return(status: 500) WebMock.stub(:get, "body_example.com").to_return(body: "hello") diff --git a/spec/spec_helper.cr b/spec/spec_helper.cr index a3591f8..f3568cc 100644 --- a/spec/spec_helper.cr +++ b/spec/spec_helper.cr @@ -1,2 +1,3 @@ require "spec" +require "webmock" require "../src/mechanize"