spec/layout_treemap_spec.rb in rubyvis-0.6.1 vs spec/layout_treemap_spec.rb in rubyvis-0.7.0
- old
+ new
@@ -1,10 +1,10 @@
require File.expand_path(File.dirname(__FILE__)+"/spec_helper.rb")
describe Rubyvis::Layout::Treemap do
include Rubyvis::LayoutSpec
it "should have correct properties" do
- props=[:antialias, :bottom, :canvas, :cursor, :data, :events, :fill_style, :height, :id, :left, :line_width, :links, :mode, :nodes, :order, :overflow, :padding_bottom, :padding_left, :padding_right, :padding_top, :reverse, :right, :round, :stroke_style, :title, :top, :transform, :visible, :width].inject({}) {|ac, v| ac[v]=true; ac}
+ props=[:antialias, :bottom, :canvas, :cursor, :data, :events, :fill_style, :height, :id, :left, :line_width, :links, :mode, :nodes, :order, :overflow, :padding_bottom, :padding_left, :padding_right, :padding_top, :reverse, :right, :round, :stroke_style, :title, :top, :transform, :visible, :view_box, :width].inject({}) {|ac, v| ac[v]=true; ac}
Rubyvis::Layout::Treemap.properties.should==props
end
describe "rendered" do
before do
color=pv.Colors.category19
@@ -33,9 +33,9 @@
@pv_out=fixture_svg_read("layout_treemap.svg")
end
it "should render equal to protovis version " do
- @vis.to_svg.should have_same_svg_elements(@pv_out)
+ expect(@vis.to_svg).to have_same_svg_elements(@pv_out)
end
end
end