net-dns/dnssec-check: use HTTPS
[gentoo.git] / dev-ruby / http / http-3.0.0.ebuild
1 # Copyright 1999-2018 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5 USE_RUBY="ruby22 ruby23 ruby24"
6
7 RUBY_FAKEGEM_RECIPE_TEST="rspec3"
8
9 RUBY_FAKEGEM_RECIPE_DOC="rdoc"
10 RUBY_FAKEGEM_EXTRADOC="CHANGES.md README.md"
11
12 inherit ruby-fakegem
13
14 DESCRIPTION="An easy-to-use client library for making requests from Ruby"
15 HOMEPAGE="https://github.com/tarcieri/http"
16
17 LICENSE="MIT"
18 SLOT="3"
19 KEYWORDS="~amd64 ~arm ~ppc64 ~x86"
20 IUSE=""
21
22 ruby_add_rdepend "
23         >=dev-ruby/addressable-2.3
24         >=dev-ruby/http-cookie-1.0
25         >=dev-ruby/http-form_data-1.0.1:1.0
26         >=dev-ruby/http_parser_rb-0.6.0 =dev-ruby/http_parser_rb-0.6*"
27
28 ruby_add_bdepend "
29         test? ( dev-ruby/certificate_authority dev-ruby/rspec-its )"
30
31 all_ruby_prepare() {
32         sed -i -e '/simplecov/,/end/ s:^:#:' \
33                 -e '1irequire "cgi"' spec/spec_helper.rb || die
34
35         # Avoid specs that require network access
36         sed -i -e '/.persistent/,/^  end/ s:^:#:' \
37                 spec/lib/http_spec.rb || die
38         sed -i -e '/with non-ASCII URLs/,/^    end/ s:^:#:' \
39                 spec/lib/http/client_spec.rb || die
40
41         # Avoid spec that may fail with a running web server
42         sed -i -e '/unifies socket errors into HTTP::ConnectionError/,/^  end/ s:^:#:' spec/lib/http_spec.rb || die
43 }