test/test_font_options.rb in cairo-1.17.8 vs test/test_font_options.rb in cairo-1.17.9
- old
+ new
@@ -60,6 +60,25 @@
only_cairo_version(1, 15, 12)
assert_nil(@options.variations)
@options.variations = "wdth=200"
assert_equal("wdth=200", @options.variations)
end
+
+ test "color mode" do
+ only_cairo_version(1, 17, 8)
+ assert_equal(Cairo::ColorMode::DEFAULT, @options.color_mode)
+ @options.color_mode = Cairo::ColorMode::COLOR
+ assert_equal(Cairo::ColorMode::COLOR, @options.color_mode)
+ end
+
+ test "color palette" do
+ only_cairo_version(1, 17, 8)
+ assert_equal(Cairo::ColorPalette::DEFAULT, @options.color_palette)
+ @options.set_custom_palette_color(1,
+ 1.0,
+ 0.2,
+ 0.0,
+ 0.8)
+ @options.color_palette = 1
+ assert_equal(1, @options.color_palette)
+ end
end