Sha256: e766c0f7eb3b0263c2fcf6d0acaeff227ff78f988f6f852b3ded5528e5217746

Contents?: true

Size: 629 Bytes

Versions: 9

Compression:

Stored size: 629 Bytes

Contents

require 'tc_helper.rb'

class TestSeries < Test::Unit::TestCase

  def setup
    p = Axlsx::Package.new
    @ws = p.workbook.add_worksheet :name=>"hmmm"
    chart = @ws.drawing.add_chart Axlsx::Chart, :title => "fishery"
    @series = chart.add_series :title=>"bob"
  end

  def test_initialize
    assert_equal(@series.title.text, "bob", "series title has been applied")
    assert_equal(@series.order, @series.index, "order is index by default")
    assert_equal(@series.index, @series.chart.series.index(@series), "index is applied")
  end

  def test_order
    @series.order = 2
    assert_equal(@series.order, 2)
  end

end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
axlsx-1.1.8 test/drawing/tc_series.rb
axlsx-1.1.7 test/drawing/tc_series.rb
axlsx-1.1.6 test/drawing/tc_series.rb
axlsx-1.1.5 test/drawing/tc_series.rb
axlsx-1.1.4 test/drawing/tc_series.rb
axlsx-1.1.3 test/drawing/tc_series.rb
axlsx-1.1.2 test/drawing/tc_series.rb
axlsx-1.1.1 test/drawing/tc_series.rb
axlsx-1.1.0 test/drawing/tc_series.rb