circleci
1 of 2 new or added lines in 1 file covered. (50.0%)
2136 existing lines in 138 files now uncovered.3967 of 6302 relevant lines covered (62.95%)
75.79 hits per line
1 |
# frozen_string_literal: true
|
|
2 |
|
|
3 |
class EzProxyService |
1✔ |
4 |
def self.ez_proxy_url?(url) |
1✔ |
UNCOV
5
|
host = URI(url.to_s).host |
× |
UNCOV
6
|
EZ_PROXY_HOST_LIST.include?(host)
|
× |
7 |
rescue URI::InvalidURIError |
|
UNCOV
8
|
Rails.logger.warn("EzProxyService encountered bad url: #{url}") |
× |
UNCOV
9
|
false
|
× |
10 |
end
|
|
11 |
|
|
12 |
def self.ez_proxy_url(url) |
1✔ |
UNCOV
13
|
if EzProxyService.ez_proxy_url?(url) |
× |
UNCOV
14
|
"#{Requests.config['proxy_base']}#{url}"
|
× |
15 |
else
|
|
UNCOV
16
|
url.to_s |
× |
17 |
end
|
|
18 |
end
|
|
19 |
end
|