[DRE-commits] [SCM] ruby-yajl.git branch, master, updated. debian/0.8.3-2-11-g47e922d
Praveen Arimbrathodiyil
pravi.a at gmail.com
Tue Sep 27 08:16:16 UTC 2011
The following commit has been merged in the master branch:
commit 437fc45b35447d84049cb2550c2e718a354db587
Author: Praveen Arimbrathodiyil <pravi.a at gmail.com>
Date: Tue Sep 27 01:25:11 2011 +0530
add upstream patch to fix test failure.
diff --git a/debian/changelog b/debian/changelog
index 7a427d3..e451fb0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,7 +1,9 @@
ruby-yajl (1.0.0-1) unstable; urgency=low
* New upstream release.
- * Remove 0001-Fix-installation-path-of-native-extension.patch (merged upstream)
+ * Remove 0001-Fix-installation-path-of-native-extension.patch
+ - merged upstream
+ * Add 001-encoding-spec-upstream-fix.patch to fix test failures.
-- Praveen Arimbrathodiyil <pravi.a at gmail.com> Thu, 22 Sep 2011 00:07:45 +0530
diff --git a/debian/patches/001-encoding-spec-upstream-fix.patch b/debian/patches/001-encoding-spec-upstream-fix.patch
new file mode 100644
index 0000000..235dc64
--- /dev/null
+++ b/debian/patches/001-encoding-spec-upstream-fix.patch
@@ -0,0 +1,37 @@
+From: Brian Lopez - https://github.com/brianmario
+Subject: make sure to_json doesn't exist
+
+* ext/yajl/yajl_ext.c
+* spec/encoding/encoding_spec.rb
+
+Origin: upstream, https://github.com/brianmario/yajl-ruby/commit/527f486a6754a793ff4221713bac2779736a425d
+Bug: https://github.com/brianmario/yajl-ruby/issues/83
+
+diff --git a/ext/yajl/yajl_ext.c b/ext/yajl/yajl_ext.c
+index 708b72a..9f03546 100644
+--- a/ext/yajl/yajl_ext.c
++++ b/ext/yajl/yajl_ext.c
+@@ -192,7 +192,6 @@ void yajl_encode_part(void * wrapper, VALUE obj, VALUE io) {
+ len = RSTRING_LEN(str);
+ status = yajl_gen_number(w->encoder, cptr, len);
+ } else {
+- rb_p(rb_funcall(obj, rb_intern("method"), 1, ID2SYM(intern_to_s)));
+ str = rb_funcall(obj, intern_to_s, 0);
+ Check_Type(str, T_STRING);
+ cptr = RSTRING_PTR(str);
+diff --git a/spec/encoding/encoding_spec.rb b/spec/encoding/encoding_spec.rb
+index 52bb626..e6ecfed 100644
+--- a/spec/encoding/encoding_spec.rb
++++ b/spec/encoding/encoding_spec.rb
+@@ -265,8 +265,9 @@ describe "Yajl JSON encoder" do
+
+ it "return value of #to_s must be a string" do
+ lambda {
+- val = TheMindKillerDuce.new.to_s
+- puts "Value is: #{val.inspect}"
++ if TheMindKillerDuce.send(:method_defined?, :abc)
++ TheMindKillerDuce.send(:undef_method, :to_json)
++ end
+ Yajl::Encoder.encode(TheMindKillerDuce.new)
+ }.should raise_error(TypeError)
+ end
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..ee73397
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+001-encoding-spec-upstream-fix.patch
--
ruby-yajl.git
More information about the Pkg-ruby-extras-commits
mailing list