Package: ruby-mechanize / 2.3-2

dont_require_rubygems Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
Author: Gunnar Wolf <gwolf@debian.org>
Last-Update: 2012-01-23
Forwarded: Not-needed
Description: Remove the 'rubygems' call
 Debian's pkg-ruby-extras policy disallows Rubygems to be called from
 within packages

Index: ruby-mechanize/lib/mechanize/test_case.rb
===================================================================
--- ruby-mechanize.orig/lib/mechanize/test_case.rb	2012-01-23 11:34:15.000000000 -0600
+++ ruby-mechanize/lib/mechanize/test_case.rb	2012-01-23 11:35:19.000000000 -0600
@@ -5,11 +5,14 @@
 require 'webrick'
 require 'zlib'
 
-require 'rubygems'
+# Rubygems not allowed within Debian packages per Debian Ruby policy
+# require 'rubygems'
 
 begin
-  gem 'minitest'
-rescue Gem::LoadError
+#   gem 'minitest'
+# rescue Gem::LoadError
+  require 'minitest'
+rescue LoadError
 end
 
 require 'minitest/autorun'