File: test_xml_device.rb

package info (click to toggle)
ruby-cairo 1.17.13-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,532 kB
  • sloc: ruby: 11,997; ansic: 10,183; sh: 48; makefile: 4
file content (22 lines) | stat: -rw-r--r-- 419 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
class XMLDeviceTest < Test::Unit::TestCase
  include Helper

  def setup
    only_device("XML")
  end

  def test_new
    output = StringIO.new
    device = Cairo::XMLDevice.new(output)
    assert_equal("", output.string)
  end

  def test_new_with_block
    output = StringIO.new
    string = nil
    Cairo::XMLDevice.new(output) do |device|
      string = output.string
    end
    assert_equal("", string)
  end
end