Sha256: 19adc1f1248e8070f5e10b8051b95ab0f91a629292e92878f149edc7bf8b4fe4

Contents?: true

Size: 683 Bytes

Versions: 8

Compression:

Stored size: 683 Bytes

Contents

require_relative "test_helper"

IDENTIFY_FONT_RESPONSE = <<~EO_FONTS
  Font: Zapf-Dingbats
      family: Zapf Dingbats
      style: Normal
      stretch: Normal
      weight: 400
      glyphs: /System/Library/Fonts/ZapfDingbats.ttf
    Font: Zapfino
      family: Zapfino
      style: Italic
      stretch: Normal
      weight: 400
      glyphs: /Library/Fonts/Zapfino.ttf
EO_FONTS

class FontTest < MiniTest::Test
  def test_font
    f = MojoMagick::Font.new
    assert_nil f.name
    assert_equal f.valid?, false

    f = MojoMagick::Font.new(name: "Zapfino", weight: 400)
    assert_equal f.name, "Zapfino"
    assert_equal f.valid?, true
    assert_equal f.weight, 400
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
mojo_magick-0.6.8 test/font_test.rb
mojo_magick-0.6.7 test/font_test.rb
mojo_magick-0.6.6 test/font_test.rb
mojo_magick-0.6.5 test/font_test.rb
mojo_magick-0.6.4 test/font_test.rb
mojo_magick-0.6.3 test/font_test.rb
mojo_magick-0.6.2 test/font_test.rb
mojo_magick-0.6.0 test/font_test.rb