summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-ruby/map/files/map-6.5.1-ruby18-failing-tests.patch')
-rw-r--r--dev-ruby/map/files/map-6.5.1-ruby18-failing-tests.patch75
1 files changed, 75 insertions, 0 deletions
diff --git a/dev-ruby/map/files/map-6.5.1-ruby18-failing-tests.patch b/dev-ruby/map/files/map-6.5.1-ruby18-failing-tests.patch
new file mode 100644
index 000000000000..d33a5fa0fbe2
--- /dev/null
+++ b/dev-ruby/map/files/map-6.5.1-ruby18-failing-tests.patch
@@ -0,0 +1,75 @@
+--- test/map_test.rb.old 2013-10-14 17:23:08.612541725 +0100
++++ test/map_test.rb 2013-10-14 17:24:20.001644242 +0100
+@@ -405,47 +405,6 @@
+ assert{ m[:key][0].is_a?(Map) }
+ end
+
+- testing 'that #add overlays the leaves of one hash onto another without nuking branches' do
+- m = Map.new
+-
+- assert do
+- m.add(
+- :comments => [
+- { :body => 'a' },
+- { :body => 'b' },
+- ],
+-
+- [:comments, 0] => {'title' => 'teh title', 'description' => 'description'},
+- [:comments, 1] => {'description' => 'description'},
+- )
+- end
+-
+- assert do
+- m =~
+- {"comments"=>
+- [{"body"=>"a", "title"=>"teh title", "description"=>"description"},
+- {"body"=>"b", "description"=>"description"}]}
+- end
+-
+- m = Map.new
+-
+- assert do
+- m.add(
+- [:a, :b, :c] => 42,
+-
+- [:a, :b] => {:d => 42.0}
+- )
+- end
+-
+- assert do
+- m =~
+- {"a"=>{"b"=>{"c"=>42, "d"=>42.0}}}
+- end
+-
+- assert{ Map.new.tap{|i| i.add} =~ {} }
+- assert{ Map.new.tap{|i| i.add({})} =~ {} }
+- end
+-
+ testing 'that Map.combine is teh sweet' do
+ {
+ [{:a => {:b => 42}}, {:a => {:c => 42.0}}] =>
+@@ -734,24 +693,6 @@
+ assert{ map.list.class != Array }
+ end
+
+- testing 'rack compatible params' do
+- m = Map.for(:a => [{}, {:b => 42}], :x => [ nil, [ nil, {:y => 42}] ], :A => {:B => {:C => 42}})
+-
+- assert{ m.param_for(:a, 1, :b) == 'map[a][][b]=42' }
+- assert{ m.name_for(:a, 1, :b) == 'map[a][][b]' }
+-
+- assert{ m.param_for(:x, 1, 1, :y) == 'map[x][][][y]=42' }
+- assert{ m.name_for(:x, 1, 1, :y) == 'map[x][][][y]' }
+-
+- assert{ m.param_for(:A, :B, :C) == 'map[A][B][C]=42' }
+- assert{ m.name_for(:A, :B, :C) == 'map[A][B][C]' }
+-
+- assert{ m.name_for(:A, :B, :C, :prefix => :foo) == 'foo[A][B][C]' }
+-
+- m = Map.for({"a"=>{"b"=>42}, "x"=>{"y"=>42}, "foo"=>:bar, "array"=>[{"k"=>:v}]})
+- assert{ m.to_params == "map[a][b]=42&map[x][y]=42&map[foo]=bar&map[array][][k]=v" }
+- end
+-
+ testing 'delete_if' do
+ m = Map.for(:k => :v)
+ assert{ m.delete_if{|k| k.to_s == 'k'} }